Standardising nonce storage/retrieval through redis for both login and

invite.

Signed-off-by: Cliff Hill <clifford.hill@gsa.gov>
This commit is contained in:
Cliff Hill
2024-10-15 09:27:34 -04:00
parent 82cef7dbd3
commit d0cda995cf
4 changed files with 9 additions and 9 deletions

View File

@@ -46,7 +46,7 @@ class InviteApiClient(NotifyAdminAPIClient):
# make and store the nonce
nonce = secrets.token_urlsafe()
redis_client.set(f"invitenonce-{state}", nonce) # save the nonce to redis.
redis_client.set(f"login-nonce-{state}", nonce) # save the nonce to redis.
data["nonce"] = nonce # This is passed to api for the invite url.
resp = self.post(url=f"/service/{service_id}/invite", data=data)