Skip to content

Commit 2f37cf8

Browse files
CopilotbgavrilMS
andauthored
docs: note caller-owned validation
Agent-Logs-Url: https://github.com/AzureAD/microsoft-authentication-library-for-python/sessions/d56329c6-d8ad-4440-8617-3df24459fed0 Co-authored-by: bgavrilMS <12273384+bgavrilMS@users.noreply.github.com>
1 parent a1fbc6f commit 2f37cf8

2 files changed

Lines changed: 4 additions & 0 deletions

File tree

msal/application.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1203,6 +1203,8 @@ def acquire_token_by_authorization_code(
12031203
:param nonce:
12041204
If you provided a nonce when calling :func:`get_authorization_request_url`,
12051205
this parameter is ignored and only kept for backward compatibility.
1206+
Applications that require nonce validation need to validate the ID
1207+
token nonce themselves.
12061208
12071209
:param claims_challenge:
12081210
The claims_challenge parameter requests specific claims requested by the resource provider

msal/oauth2cli/oidc.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,8 @@ def decode_id_token(id_token, client_id=None, issuer=None, nonce=None, now=None)
8484
8585
The optional parameters ``client_id``, ``issuer``, ``nonce``, and ``now``
8686
are ignored and only kept for backward compatibility.
87+
Callers that require claim validation are responsible for performing it
88+
themselves.
8789
"""
8890
return json.loads(decode_part(id_token.split('.')[1]))
8991

0 commit comments

Comments
 (0)