Skip to content

Commit 7ff1711

Browse files
wasadeclaude
andcommitted
Upgrade PyJWT to >=2.4 (CVE-2022-29217)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent 6767798 commit 7ff1711

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

ci/pip_requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
openapi-spec-validator < 0.2.10
22
swagger-ui-bundle==0.0.9
33
connexion[swagger-ui] < 2.7.1
4-
pyjwt[crypto] < 2.2.0
4+
pyjwt[crypto] >= 2.12.0, < 3.0.0
55
pytest < 5.3.4
66
pytest-cov
77
coveralls

microsetta_interface/implementation.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -779,7 +779,7 @@ def wrapper(**kwargs):
779779
# Client might not technically care who the user is, but if they do, they
780780
# get the token, validate it, and pull email out of it.
781781
def _parse_jwt(token):
782-
decoded = jwt.decode(token, PUB_KEY, algorithms=['RS256'], verify=True)
782+
decoded = jwt.decode(token, PUB_KEY, algorithms=['RS256'], options={'verify_signature': True})
783783
email_verified = decoded.get('email_verified', False)
784784
return decoded["email"], email_verified
785785

0 commit comments

Comments
 (0)