Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions msal/application.py
Original file line number Diff line number Diff line change
Expand Up @@ -1386,6 +1386,9 @@ def _acquire_token_silent_from_cache_and_possibly_refresh_it(
if expires_in < 5*60: # Then consider it expired
refresh_reason = msal.telemetry.AT_EXPIRED
continue # Removal is not necessary, it will be overwritten
if key_id and entry.get("key_id") != key_id:
refresh_reason = msal.telemetry.AT_ABSENT
continue # If the Key_Id is not matching, then it is not the token we are looking for
logger.debug("Cache hit an AT")
access_token_from_cache = { # Mimic a real response
"access_token": entry["secret"],
Expand Down