You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Snyk] Security upgrade pyjwt from 1.7.1 to 2.14.0 - #550
Snyk has created this PR to fix 1 vulnerabilities in the pip dependencies of this project.
Snyk changed the following file(s):
requirements2.txt
⚠️Warning
PyGithub 1.51 requires pyjwt, which is not installed.
Breaking Change Risk
Notice: This assessment is enhanced by AI.
Important
Check the changes in this PR to ensure they won't cause issues with your project.
Max score is 1000. Note that the real score may have changed since the PR was raised.
This PR was automatically created by Snyk using the credentials of a real user.
Some vulnerabilities couldn't be fully fixed and so Snyk will still find them when the project is tested again. This may be because the vulnerability existed within more than one direct dependency, but not all of the affected dependencies could be upgraded.
Note:You are seeing this because you or someone else with access to this repository has authorized Snyk to open fix PRs.
The upgrade from PyJWT v1.7.1 to v2.14.0 is a major version change that introduces significant and mandatory breaking changes, primarily in the jwt.decode() function. Code modifications are required for the application to function correctly.
Key Breaking Changes:
jwt.decode() requires the algorithms parameter: This is the most critical change. Previously optional, the algorithms parameter is now mandatory to prevent security vulnerabilities. Calls to decode() without this parameter will fail.
Updated Options for jwt.decode(): Several deprecated parameters have been removed and moved into an options dictionary.
Verifying claims like expiration (exp) must now be done using options={"require": ["exp"]} instead of require_exp=True.
Disabling signature verification, previously verify=False, is now done with options={"verify_signature": False}.
Python Version Support: Support for Python 2.7 and versions below 3.6 was dropped in v2.0.0. Support for Python 3.7 was dropped in v2.9.0.
Dependency Changes: Support for PyCrypto and ecdsa libraries has been removed. The library now exclusively relies on the cryptography package.
HMAC Key Validation: As of v2.13.0, empty strings ("" or b"") are no longer accepted as valid HMAC keys and will raise an InvalidKeyError. This prevents a common misconfiguration where a missing environment variable could lead to an insecure key.
Recommendation:
Developers must review every call to jwt.decode() and update it to explicitly pass the expected signing algorithms via the algorithms parameter. All other decoding options must be migrated to the new options dictionary syntax. Ensure your environment is running a supported Python version (3.8+ recommended for the latest versions in this range).
Notice 🤖: This content was augmented using artificial intelligence. AI-generated content may contain errors and should be reviewed for accuracy before use.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Snyk has created this PR to fix 1 vulnerabilities in the pip dependencies of this project.
Snyk changed the following file(s):
requirements2.txtBreaking Change Risk
Important
Note: You are seeing this because you or someone else with access to this repository has authorized Snyk to open fix PRs.
For more information:
🧐 View latest project report
📜 Customise PR templates
🛠 Adjust project settings
📚 Read about Snyk's upgrade logic
Learn how to fix vulnerabilities with free interactive lessons:
🦉 Learn about vulnerability in an interactive lesson of Snyk Learn.