summaryrefslogtreecommitdiff
path: root/oauthlib/oauth2/rfc6749
diff options
context:
space:
mode:
authorJonathan Huot <jonathan.huot@thomsonreuters.com>2019-04-26 15:59:57 +0200
committerJonathan Huot <jonathan.huot@thomsonreuters.com>2019-04-26 15:59:57 +0200
commit71be50afdeaf99a0ba6ce5048851dcdd5620d880 (patch)
treeeefd8069621e19b1addfadedd964dee12fc6a3f2 /oauthlib/oauth2/rfc6749
parent30321dd3c0ca784d3508a1970cf90d9f76835c79 (diff)
downloadoauthlib-71be50afdeaf99a0ba6ce5048851dcdd5620d880.tar.gz
Fix 670. AuthCode API must return the new PKCE attribute670-pkce-requestinfo
Diffstat (limited to 'oauthlib/oauth2/rfc6749')
-rw-r--r--oauthlib/oauth2/rfc6749/grant_types/authorization_code.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/oauthlib/oauth2/rfc6749/grant_types/authorization_code.py b/oauthlib/oauth2/rfc6749/grant_types/authorization_code.py
index 5f03d9c..9b84c4c 100644
--- a/oauthlib/oauth2/rfc6749/grant_types/authorization_code.py
+++ b/oauthlib/oauth2/rfc6749/grant_types/authorization_code.py
@@ -405,12 +405,15 @@ class AuthorizationCodeGrant(GrantTypeBase):
raise errors.MissingCodeChallengeError(request=request)
if request.code_challenge is not None:
+ request_info["code_challenge"] = request.code_challenge
+
# OPTIONAL, defaults to "plain" if not present in the request.
if request.code_challenge_method is None:
request.code_challenge_method = "plain"
if request.code_challenge_method not in self._code_challenge_methods:
raise errors.UnsupportedCodeChallengeMethodError(request=request)
+ request_info["code_challenge_method"] = request.code_challenge_method
# OPTIONAL. The scope of the access request as described by Section 3.3
# https://tools.ietf.org/html/rfc6749#section-3.3