Skip to content

Commit

Permalink
Fix apparent typo in call to jwt.decode()
Browse files Browse the repository at this point in the history
Used `algorithm='RS256'` as is done with jwt.encode() but
in decode() it's plural `algorithms` and it sets which algorithms
are valid -- so it needs to be a list and not a string.
  • Loading branch information
shaib committed Dec 29, 2020
1 parent 39e4756 commit 4937977
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion social_core/backends/apple.py
Expand Up @@ -125,7 +125,7 @@ def decode_id_token(self, id_token):
id_token,
key=public_key,
audience=self.get_audience(),
algorithm='RS256',
algorithms=['RS256'],
)
except PyJWTError:
raise AuthFailed(self, 'Token validation failed')
Expand Down

0 comments on commit 4937977

Please sign in to comment.