acme_certificate: make compatible to Buypass' ACME v2 testing endpoint (#60727)

* Don't unnecessarily use location from header.

* Add changelog.
This commit is contained in:
Felix Fontein 2019-08-26 18:19:55 +02:00 committed by GitHub
parent 039123ec6b
commit 7f4f2506a0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View file

@ -0,0 +1,2 @@
bugfixes:
- "acme_certificate - improve compatibility when finalizing ACME v2 orders. Fixes problem with Buypass' ACME v2 testing endpoint."

View file

@ -677,12 +677,10 @@ class ACMEClient(object):
if info['status'] not in [200]:
raise ModuleFailException("Error new cert: CODE: {0} RESULT: {1}".format(info['status'], result))
order = info['location']
status = result['status']
while status not in ['valid', 'invalid']:
time.sleep(2)
result, dummy = self.account.get_request(order)
result, dummy = self.account.get_request(self.order_uri)
status = result['status']
if status != 'valid':