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

@@ -170,7 +170,7 @@ def set_up_your_profile():
request_json = request.json()
id_token = get_id_token(request_json)
nonce = id_token["nonce"]
stored_nonce = redis_client.get(f"invitenonce-{state}")
stored_nonce = redis_client.get(f"login-nonce-{state}")
if nonce != stored_nonce:
current_app.logger.error(f"Nonce Error: {nonce} != {stored_nonce}")
abort(403)