fix(google-auth): raise cryptography lower bounds - #18261
Conversation
|
Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). View this failed invocation of the CLA check for more information. For the most up to date status, view the checks section at the bottom of the pull request. |
There was a problem hiding this comment.
Code Review
This pull request updates the minimum required versions of the cryptography dependency in setup.py, bumping it to >= 46.0.5 for Python versions below 3.14 and to >= 50.0.1 for Python versions 3.14 and above. The corresponding pinned versions in the testing constraint files (constraints-3.10.txt and constraints-3.14.txt) have also been updated to match. There are no review comments, and I have no feedback to provide.
cryptography 41.0.5 has no Python 3.14 wheels, so unit tests cannot resolve the 3.14 constraints pin. Require 50.0.1, which is the first release with Python 3.14 support.
Require cryptography 46.0.5, which fixes CVE-2026-26007, and pin the same version in the 3.10 lower-bound constraints.
fcb664c to
f72b141
Compare
|
Hey @j-flat, thanks for looking in to this
In general, we do not bump up dependency ranges due to reported CVEs. Our policy is to allow customers to manage their own patching cadence unless a vulnerability renders the library fundamentally insecure in standard configurations. Bumping up the minimum dependency comes with a cost to users, so we prefer to leave the decision in their hands. These specific CVEs (CVE-2026-26007, CVE-2023-49083) should not be relevant to google-auth, because we do not use the impacted methods, so we should not bump versions for that reason alone.
How are you determining 3.14 support? I could be in favor of bumping this, seeing that the current lower bound doesn't declare 3.14 support. But |
Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly:
Fixes #18260 🦕
Summary
Raise the
cryptographylower bound ingoogle-authso unit tests can install on Python 3.14 and so older Pythons no longer allow releases with known high-severity CVEs.>= 38.0.3>= 46.0.5>= 41.0.5>= 50.0.1Lower-bound constraints are updated to match:
testing/constraints-3.10.txtpins46.0.5,testing/constraints-3.14.txtpins50.0.1.Rationale
cryptography==41.0.5has no 3.14 wheels, sonox -s unit-3.14fails withResolutionImpossible.50.0.1is the first release with Python 3.14 support.46.0.5is the first release that fixes CVE-2026-26007. The previous floor (38.0.3, and the 3.14 pin of41.0.5) also included CVE-2023-49083.This does not pin users to a specific
cryptographyversion. Pip still installs a current compatible release unless something else constrains it. Anyone still depending oncryptography < 46.0.5(or< 50.0.1on 3.14) will need to upgrade that package.Test plan
nox -s unit-3.12(or another 3.10–3.13 interpreter) inpackages/google-authnox -s unit-3.14inpackages/google-authcryptography==41.0.5on 3.14