-
-
Notifications
You must be signed in to change notification settings - Fork 688
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PyJWT 2.6.0 IAT Decode Error - TypeError: '>' not supported between instances of 'str' and 'int' #817
Comments
+1, same for me my test is import jwt
decoded = jwt.decode(data, pub_key, algorithms=["RS512"])
print(decoded) |
Happy to provide also a full stack trace
|
I tried out other versions and can verify that it stops working with version 2.0. |
Do we have an update on this ? Seems like a pretty big regression, how come it does not happen to more people, did we miss something or were we not supposed to use this function ? |
Thanks for the fix 🙂 |
@jpadilla sorry to disturb you. can I do a release? |
@alexforster I was using this fix for my production builds. But @Viicos deleted his repos containing his fix. Would appreciate if a 2.6.1 with this fix could be release. Until, i'll cherry-pick in my |
@Uranium2 sorry for that, I try to keep my repositories tab clean. But I think with all the new features merged into master, the fact that is has been asked several times (#867), I think it would be great to have a new release (with #863 and #881 as well). @jpadilla @auvipy do you think that could be possible? |
Summary
Just upgraded to version
2.6.0
and now whenever I try to do a decode of a JWT I get the following error:It appears that the
iat
value is "trying" to be converted (and if not, raises an exception) but doesn't actually evaluate theiat
value as an int.My payload comes across like:
So trying to perform
>
operations on that will result in a string. This does not happen in version2.5.0
so I believe this is a regression.Expected Result
A valid decode of my JWT value:
Actual Result
Reproduction Steps
System Information
This command is only available on PyJWT v1.6.3 and greater. Otherwise,
please provide some basic information about your system.
The text was updated successfully, but these errors were encountered: