Repository navigation
chore: raise the minimum jwcrypto to 1.6.3 - #192
Open
frederikprijck wants to merge 2 commits into
Open
frederikprijck wants to merge 2 commits into
frederikprijck wants to merge 2 commits into
Conversation
Raise the declared minimum to the first release that parses a JWKS containing keys of an unknown type and supports newer JOSE algorithms and the `AKP` key type without requiring a newer `cryptography` than the repo declares. No major version bump. - pyproject.toml: jwcrypto ^1.5.7 -> ^1.6.2 - requirements.txt: jwcrypto >=1.5.6,<2.0.0 -> >=1.6.2,<2.0.0 - poetry.lock: jwcrypto 1.5.7 -> 1.6.3 and the content hash; no other package moves (cryptography stays at 43.0.3) Co-Authored-By: Claude <noreply@anthropic.com>
1.6.3 contains the fix for CVE-2026-142105, which affects every release up to 1.6.2. It has the same requirements as 1.6.2 (cryptography>=39.0.0), and the lockfile already resolved it. Co-Authored-By: Claude <noreply@anthropic.com>
This branch has not been deployed
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Changes
Raise the declared
jwcryptominimum from^1.5.7to^1.6.3. This is the first release with all the security fixes since 1.5.7 (CVE-2026-80179 (fixed in 1.5.9), CVE-2026-84185 (1.6.0), CVE-2026-92091 (1.6.1) and CVE-2026-142105 (1.6.3); the last affects every release up to 1.6.2) and, like 1.5.9 and later, parses a JWKS containing keys of an unknown type and supports newer JOSE algorithms and theAKPkey type without requiring a newercryptographythan this repo declares. There is no major version bump and no source change.pyproject.toml:jwcrypto = "^1.5.7"->"^1.6.3"requirements.txt:jwcrypto>=1.5.6,<2.0.0->>=1.6.3,<2.0.0(kept in step withpyproject.toml, asCLAUDE.mdasks, because Snyk SCA installs from it)poetry.lock:jwcrypto1.5.7 -> 1.6.3 plus the content hash. Nothing else moves;cryptographystays at 43.0.3. Lockfile generated with Poetry 2.3.4, the version that wrote the existing file.Dependency constraints (from PyPI):
>=3.8>=3.4>=3.9>=49.0.0>=3.9>=39.0.0>=3.9>=39.0.01.5.9 to 1.6.1 need
cryptography>=49.0.0, which is why the minimum is not 1.5.9. It is 1.6.3 and not 1.6.2 because CVE-2026-142105 (affects every release up to 1.6.2) is fixed only in 1.6.3. The repo's declaredpython = ">=3.9"andcryptography = ">=43.0.1"stay valid.Where this repo uses
jwcrypto: JWE encrypt/decrypt of session data (encryption/encrypt.py,dir+A256CBC-HS512) and DPoP key handling and proof signing (auth_schemes/dpop_auth.py). Incoming JWTs and JWKS are verified with PyJWT, notjwcrypto.Behaviour changes between 1.5.7 and 1.6.3 worth knowing (from the release notes):
base64url_decodenow rejects non-canonical input (padding bits, stray=). Encrypted sessions written by 1.5.7 and by 1.6.3 decrypt with either version (checked, see Testing).exp/nbf/iatmust be integers and null claim values are rejected. This applies only tojwcrypto.jwtverification, which this repo does not use for incoming tokens; the DPoP proof is only generated here.zipmust be in the protected header, and JWS/JWE header merging was unified. The SDK writes onlyalg/encin the protected header.dirflow used here.kty(RFC 7517 section 5) and wraps JWKSet parse errors inInvalidJWKValue. The security fixes (CVE-2026-80179 (fixed in 1.5.9), CVE-2026-84185 (1.6.0), CVE-2026-92091 (1.6.1) and CVE-2026-142105 (1.6.3)) come with the new minimum. Advisories: https://github.com/latchset/jwcrypto/security/advisoriesReferences
Testing
Run
poetry installthenpoetry run pytestandpoetry run ruff check ..poetry installAll tests run, no Docker needed. Also checked that a session encrypted with
encrypt()under jwcrypto 1.5.7 decrypts under 1.6.3 and the reverse. No tests were added because there is no source change. Not run: Python 3.10, 3.11, 3.13 and newer, and the CI matrix itself.The platform/language item is left unticked: it was tested on Python 3.9 and 3.12 only, not the newest Python release.
Checklist
🤖 Generated with Claude Code