Make sure to iterate over a copy of the public_keys dictionary
This commit is contained in:
parent
f75949d533
commit
71b2853f40
1 changed files with 1 additions and 1 deletions
|
@ -26,7 +26,7 @@ class InstanceKeys(object):
|
|||
keys[key.kid] = ExpiresEntry(key, key.expiration_date)
|
||||
|
||||
# Remove any expired or deleted keys from the public keys cache.
|
||||
for key in self.public_keys:
|
||||
for key in dict(self.public_keys):
|
||||
if key not in keys:
|
||||
self.public_keys.pop(key)
|
||||
|
||||
|
|
Reference in a new issue