-
Notifications
You must be signed in to change notification settings - Fork 6.5k
chore(deps): update dependency cryptography to v45 #13375
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
base: main
Are you sure you want to change the base?
chore(deps): update dependency cryptography to v45 #13375
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hello @renovate-bot, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!
Summary of Changes
Hello team, gemini-code-assist here to provide a summary of this pull request. This PR, automatically generated by renovate-bot, focuses on a routine dependency update. The primary goal is to upgrade the cryptography
Python package to its latest version, 45.0.1
, from the previous version 44.0.2
. This update is applied across several requirements.txt
files within different sample directories to ensure they are using the most current and potentially more secure or performant version of the library.
Highlights
- Dependency Update: The core change is the update of the
cryptography
Python dependency from version44.0.2
to45.0.1
. - Affected Files: This dependency version bump is applied to the
requirements.txt
files located in the following directories:compute/encryption
,iap
,kms/attestations
,kms/snippets
,media_cdn
, andprivateca/snippets
(specificallyrequirements-test.txt
).
Changelog
Click here to see the changelog
- compute/encryption/requirements.txt
- Updated
cryptography
dependency from44.0.2
to45.0.1
.
- Updated
- iap/requirements.txt
- Updated
cryptography
dependency from44.0.2
to45.0.1
.
- Updated
- kms/attestations/requirements.txt
- Updated
cryptography
dependency from44.0.2
to45.0.1
.
- Updated
- kms/snippets/requirements.txt
- Updated
cryptography
dependency from44.0.2
to45.0.1
.
- Updated
- media_cdn/requirements.txt
- Updated
cryptography
dependency from44.0.2
to45.0.1
.
- Updated
- privateca/snippets/requirements-test.txt
- Updated
cryptography
dependency from44.0.2
to45.0.1
.
- Updated
Using Gemini Code Assist
The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.
Invoking Gemini
You can request assistance from Gemini at any point in your pull request via creating an issue comment (i.e. comment on the pull request page) using either /gemini <command>
or @gemini-code-assist <command>
. Below is a summary of the supported commands.
Feature | Command | Description |
---|---|---|
Code Review | /gemini review |
Performs a code review for the current pull request in its current state. |
Pull Request Summary | /gemini summary |
Provides a summary of the current pull request in its current state. |
Comment | @gemini-code-assist | Responds in comments when explicitly tagged, both in issue comments and review comments. |
Help | /gemini help |
Displays a list of available commands. |
Customization
To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/
folder in the base of the repository. Detailed instructions can be found here.
Limitations & Feedback
Gemini Code Assist is currently in preview and may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments to provide feedback.
You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.
A package version, old and slow,
Renovate helps the numbers grow.
From forty-four to forty-five,
Keep dependencies alive.
Footnotes
-
Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
This pull request, generated by Mend Renovate, updates the cryptography
dependency from version 44.0.2
to 45.0.1
across multiple requirements.txt
files.
This is a beneficial update as cryptography
v45.x includes:
- Security hardening through stricter validation (these are the backward-incompatible changes noted below).
- Bug fixes (e.g., in PEM-encoded EC private key loading, PKCS12 handling).
- Support for new algorithms like AES-GCM-SIV and HKDF-Expand-Label.
- Updated OpenSSL version (3.2.1) for pre-built wheels.
The primary consideration for this update is cryptography
v45.0.0, which introduced several backward-incompatible changes and deprecations:
Backward-Incompatible Changes (v45.0.0):
- Stricter validation for DSA key loading (
load_pem_private_key
,load_der_private_key
) regardingq
lengths. - Stricter validation in
DHParameterNumbers.validate_private_key
. - Stricter validation in
DSAParameterNumbers.validate_private_key
. - Stricter validation in
DSAPublicNumbers.verify_signature
. EllipticCurvePrivateKey.exchange
now errors if the peer public key is on a different curve.utils.int_from_bytes
andutils.int_to_bytes
now requirebyteorder
to bebig
orlittle
.
Deprecations (v45.0.0):
encode_point
andfrom_encoded_point
onEllipticCurvePublicNumbers
.signer
andverifier
methods onCMAC
.update_into
andfinalize_into
methods onHash
andHMAC
.
A review of the Python files in this repository that utilize cryptography
(either directly or via libraries like PyJWT and jwcrypto) suggests that the current codebase does not directly use the APIs affected by the backward-incompatible changes. The samples primarily use RSA and Ed25519, and the affected changes are mostly related to DSA, DH, and specific EC operations or utility functions not commonly exposed or used in these samples.
Therefore, the risk of this update breaking existing functionality appears low, but thorough CI testing is essential to confirm this. The benefits of the update, especially security hardening and bug fixes, are valuable.
Summary of Findings
- Dependency Update with Backward-Incompatible Changes: The
cryptography
library is updated fromv44.0.2
tov45.0.1
. Version45.0.0
(part of this update range) introduces several documented backward-incompatible changes, primarily focused on stricter validation for DSA and DH parameters, and specific Elliptic Curve operations. A review of the repository's Python code indicates that these specific changes are unlikely to directly impact the current usage patterns, making the direct risk to this codebase low. This was assessed as a low-severity concern for the current code, and per review settings, a specific code comment was not added for low-severity items. Maintainers should be aware of these changes and rely on comprehensive CI testing to ensure full compatibility. This update also brings beneficial security hardening, bug fixes, and deprecations of some older APIs.
Merge Readiness
This dependency update to cryptography
v45.0.1 appears to be a positive change, bringing security enhancements and bug fixes. While there are backward-incompatible changes in this new version, they don't seem to directly affect the analyzed codebase.
It is recommended to ensure all continuous integration checks and tests pass successfully before merging. As an AI reviewer, I am not authorized to approve pull requests. Please ensure this change is reviewed and approved by a human maintainer.
This PR contains the following updates:
==44.0.2
->==45.0.1
Release Notes
pyca/cryptography (cryptography)
v45.0.1
Compare Source
v45.0.0
Compare Source
v44.0.3
Compare Source
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Never, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.