Bump cryptography from 46.0.5 to 50.0.0 - #730
Conversation
🔵 Review postedLast updated: 2026-08-08 05:46 UTC |
rtibblesbot
left a comment
There was a problem hiding this comment.
PR #730 — cryptography 46.0.5 → 50.0.0 (claimed), multi-major, transitive production dependency via the google_drive extra. CI passing (15/15). Requesting changes because the lockfile does not do what the title says.
What the lockfile actually does: cryptography is removed entirely (grep -c cryptography uv.lock → 0), google-auth is downgraded 2.49.1 → 2.47.0, and rsa 4.9.1 is re-added. No cryptography entry exists at any version after this change.
[[package]]
name = "google-auth"
-version = "2.49.1"
+version = "2.47.0"
dependencies = [
- { name = "cryptography" },
{ name = "pyasn1-modules" },
+ { name = "rsa" },
]Root cause: cryptography 50.0.0 was published 2026-07-31, inside the repo's rolling exclude-newer = "7 days" cooldown (pyproject.toml:86). Dependabot doesn't apply that cooldown when picking a target, so uv couldn't select 50.0.0 and instead found a resolution where cryptography isn't required at all — reachable only by walking google-auth back to 2.47.0, the last release where cryptography is an extra rather than a hard requirement (2.49.1 lists cryptography>=38.0.3 unconditionally; 2.47.0 lists rsa<5,>=3.1.4 + cryptography>=38.0.3; extra == "cryptography").
Regression this hides: google-auth 2.48.0 added cryptography as a required dependency and 2.49.0 removed the deprecated rsa dependency. Reverting to 2.47.0 puts RSA signature verification for Google service-account credentials back on pure-Python rsa, and drops the 2.48/2.49 fixes (NO_GCE_CHECK handling, configurable GCE metadata retries, mTLS IAM domain support, circular-import fix). google-auth ships to users via the google_drive extra (pyproject.toml:50) and is exercised by the Google Drive transfer handler — production surface, not dev-only.
CI green is not evidence here. CI does install the extra (.github/workflows/pythontest.yml:127), so it confirms google-auth 2.47.0 + rsa still work. It says nothing about whether dropping cryptography was correct: nothing in the suite requires cryptography to be installed. The only reference is tests/pipeline/test_transfer.py:74-92, a generate_test_private_key() helper that is never called and swallows the ImportError.
Security context: the 50.0.0 fix is CVE-2026-69247, a Bleichenbacher oracle in pkcs7_decrypt_der and its PEM/S-MIME variants. Neither ricecooker nor google-auth's credential code decrypts untrusted PKCS#7, so there's no reachable exposure and no urgency to force-land 50.0.0.
Suggested resolution: close this PR and either re-run dependabot after 2026-08-07 when 50.0.0 clears the cooldown, or land the natural upgrade deliberately. On main, uv lock --upgrade-package cryptography resolves cleanly, keeps google-auth at 2.49.1, introduces no rsa, and splits by marker:
{ name = "cryptography", version = "47.0.0", marker = "python_full_version <= '3.9'" },
{ name = "cryptography", version = "49.0.0", marker = "python_full_version > '3.9'" },
If taking that path, note two BACKWARDS INCOMPATIBLE entries in 49.0.0 — x86_64 macOS support removed, 32-bit Windows support removed. CI runners are unaffected (macos-latest is arm64, windows-latest is x64); the exposure is Intel-Mac chef authors installing ricecooker[google_drive] on Python ≥ 3.10, who would need to build from source. No API-level breaking change in 47.0.0–50.0.0 touches this project — there are no direct cryptography imports outside the dead test helper.
Separately worth checking: .github/dependabot.yml:11 sets cooldown.default-days: 7 for the uv ecosystem, matching exclude-newer, yet this PR was opened for a 4-day-old release. If dependabot's cooldown isn't honoured for uv, this failure mode recurs on every fast-moving transitive dependency — and each recurrence looks like a normal green bump.
@rtibblesbot's comments are generated by an LLM, and should be evaluated accordingly
How was this generated?
Ran a dependency-update review pipeline over the version bump:
- Classified the bump by semver (patch / minor / major) and dependency type (production vs. development)
- Extracted the changelog and release notes across the version range
- Assessed compatibility with this project's usage and whether any code changes are required
- Treated CI as the primary safety net
- Scaled the review depth to the update's risk
- Chose the verdict from semver risk, changelog findings, and CI status
|
@dependabot recreate |
Bumps [cryptography](https://github.com/pyca/cryptography) from 46.0.5 to 50.0.0. - [Changelog](https://github.com/pyca/cryptography/blob/main/CHANGELOG.rst) - [Commits](pyca/cryptography@46.0.5...50.0.0) --- updated-dependencies: - dependency-name: cryptography dependency-version: 50.0.0 dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com>
9fe4c80 to
a62ca31
Compare
rtibblesbot
left a comment
There was a problem hiding this comment.
PR #730 — cryptography 46.0.5 → 50.0.0 (major, 4 majors; transitive production dep via google-auth). CI green (19/19). 1 of 2 prior findings resolved; 1 still open.
Changelog across 47–50: no API change touches this project (no direct cryptography imports outside the dead generate_test_private_key() helper in tests/pipeline/test_transfer.py). Two BACKWARDS INCOMPATIBLE entries in 49.0.0 — x86_64 macOS and 32-bit Windows support dropped — don't affect CI runners (macos-latest is arm64, windows-latest is x64). Security: 50.0.0 is the CVE fix this bump exists for.
[blocking] uv.lock:537 — the cryptography==50.0.0 pin downgrades google-auth and re-adds rsa on Python ≤ 3.9
The lockfile forks google-auth: 2.47.0 for python_full_version <= '3.9', 2.49.1 above. cryptography appears once at 50.0.0 (uv.lock:340), referenced only by the 2.49.1 branch (uv.lock:563). 2.47.0 is the last release where cryptography is an extra rather than a hard requirement, so the 3.9 fork gets no cryptography at all and pulls in rsa 4.9.1 (uv.lock:2342), a package main does not have — pure-Python RSA verification for Google service-account credentials, and no CVE fix.
This is now avoidable. 50.0.0 published 2026-07-31T14:23Z; the repo's exclude-newer = "7 days" cooldown cleared it 2026-08-07T14:23Z. Running the natural upgrade on main (uv 0.12.3, same cooldown):
$ uv lock --upgrade-package cryptography
Resolved 151 packages in 2.01s
Updated cryptography v46.0.5 -> v47.0.0, v50.0.0
Diffed against this PR's lockfile, the only differences are: rsa 4.9.1 and google-auth 2.47.0 present only here, cryptography 47.0.0 present only in the natural resolve. That keeps google-auth at 2.49.1 everywhere, adds no rsa, and covers the ≤ 3.9 fork with 47.0.0. Dependabot can't reach it because it pins cryptography==50.0.0 across the whole resolution and so can't pick a lower version inside the 3.9 fork.
Suggested resolution: close this PR and land uv lock --upgrade-package cryptography from main. Same 50.0.0 above 3.9, no google-auth regression, no new rsa.
CI passing on all three Python 3.9 jobs confirms 2.47.0 + rsa still work, not that dropping cryptography on 3.9 is correct — nothing in the suite requires it to be importable.
Prior-finding status
RESOLVED — uv.lock — cryptography removed from the lockfile entirely at every version
UNADDRESSED — uv.lock:537 — google-auth downgraded 2.49.1 → 2.47.0 and rsa 4.9.1 re-added; now scoped to Python ≤ 3.9, and now avoidable since 50.0.0 cleared the exclude-newer cooldown
UNADDRESSED — .github/dependabot.yml:11 — cooldown.default-days: 7 appears not to be honoured for the uv ecosystem; out of scope for this branch diff, but the failure mode recurs on every fast-moving transitive dependency
@rtibblesbot's comments are generated by an LLM, and should be evaluated accordingly
How was this generated?
Ran a dependency-update review pipeline over the version bump:
- Classified the bump by semver (patch / minor / major) and dependency type (production vs. development)
- Extracted the changelog and release notes across the version range
- Assessed compatibility with this project's usage and whether any code changes are required
- Treated CI as the primary safety net
- Scaled the review depth to the update's risk
- Chose the verdict from semver risk, changelog findings, and CI status
Bumps cryptography from 46.0.5 to 50.0.0.
Changelog
Sourced from cryptography's changelog.
... (truncated)
Commits
dcb7050Prepare for 50.0.0 release (#15372)53fccd9Don't leak how PKCS#7 encryptedKey decryption failed (#15369)d472f97Addfrom __future__ import annotationsto all src/ Python files (#15371)908773dBump downstream dependencies in CI (#15368)2cc07ccBump BoringSSL, OpenSSL, AWS-LC in CI (#15367)c94ede9chore(deps): bump ruff from 0.16.0 to 0.16.1 (#15366)67a8308chore(deps): bump virtualenv from 21.7.0 to 21.7.1 (#15365)95018ffRelease the GIL in one-shot AEAD encrypt/decrypt (#15361)6954733Release the GIL during DH and DSA parameter generation (#15364)6893b94Import _serialization instead of serialization in x509/extensions (#15363)