Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix hitting flood protection #10

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

br4nnigan
Copy link

you could probably get the exact value for flood protection from the first reponse but I dont know how as I'm not proficient in python and this works too

fetzerch added a commit that referenced this pull request May 25, 2023
Every API call contains a field 'KasFloodDelay' in the result.
Wait this amount of seconds before attempting the next request.

Fix #9.
Supersede #10.
@fetzerch
Copy link
Owner

Can you please give #11 a try? The server indeed contains the number of seconds to wait in every response.

@br4nnigan
Copy link
Author

br4nnigan commented May 30, 2023

I tested it and actually I'm not so sure anymore if the flood protection has been the problem in the first place (I dont remember specifically). The flood protection isn't a problem anymore anyway.

The problem I identified now is that certbot pulls an outdated txt record. This occurs almost randomly, I added a delay like in my original pull request in suspicion that the certbot checks the record before the change is live. Sometimes I would even get a success at 1s delay, I increased it to 3, 5, 10. I'm still getting an error in half the cases. Now 10s is high enough to verify myself that the change is live while the script is sleeping and before certbot checks and it still failed, which is odd.

Now these delays to wait for propagation of the dns record seem to be essential, for example the "official" authenticator plugin for cloudflare uses a default of 10 seconds. But even at 30 (!) seconds I can't reliably get a success.

Creating a cron job to renew certs seems out of question as it must be reliable.

fetzerch added a commit that referenced this pull request Jul 9, 2023
Every API call contains a field 'KasFloodDelay' in the result.
Wait this amount of seconds before attempting the next request.

Fix #9.
Supersede #10.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants