authority.v2: Properly clear the nonce cache on using it's content

This commit is contained in:
Kishi85 2019-06-11 09:49:06 +02:00
parent 7475d5e73f
commit af0bb45d73
1 changed files with 4 additions and 1 deletions

View File

@ -97,8 +97,11 @@ class ACMEAuthority(AbstractACMEAuthority):
# Request a new nonce if there is none in cache
if not self.nonce:
self._request_url(self.directory['newNonce'])
# Set request nonce to current cache value
protected["nonce"] = self.nonce
# Reset nonce cache as we are using it's current value
self.nonce = None
protected["url"] = url
if self.algorithm:
protected["alg"] = self.algorithm