Skip to content

[Snyk] Security upgrade cryptography from 2.9.2 to 49.0.0 - #106

Open
snyk-io[bot] wants to merge 1 commit into
masterfrom
snyk-fix-fbcc4147e862c4089529b8cfa16cd733
Open

[Snyk] Security upgrade cryptography from 2.9.2 to 49.0.0#106
snyk-io[bot] wants to merge 1 commit into
masterfrom
snyk-fix-fbcc4147e862c4089529b8cfa16cd733

Conversation

@snyk-io

@snyk-io snyk-io Bot commented Aug 4, 2026

Copy link
Copy Markdown

snyk-top-banner

Snyk has created this PR to fix 2 vulnerabilities in the pip dependencies of this project.

Snyk changed the following file(s):

  • tested_requirements/requirements_37.txt

Breaking Change Risk

Merge Risk: High

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.

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:

🦉 Allocation of Resources Without Limits or Throttling

@snyk-io

snyk-io Bot commented Aug 4, 2026

Copy link
Copy Markdown
Author

Merge Risk: High

This is an extremely large major version upgrade, from 2.9.2 to 49.0.0, and contains numerous significant breaking changes. A direct upgrade is not feasible and will require a significant migration effort.

Key Breaking Changes:

  • Build & Installation:

    • Rust is now a mandatory build dependency. Starting with version 3.5, a Rust toolchain is required to build cryptography from source. While pre-compiled wheels are available for most common platforms (which include the Rust components), this is a major change for environments that build from source or use less common architectures.
    • The method for linking against a custom OpenSSL version changed in v40.0.0. Environment variables like CFLAGS and LDFLAGS are no longer used.
  • Python Version Support:

    • Version 2.9.2 supported Python 2.7 and 3.5+.
    • Version 49.0.0 requires Python 3.9 or later. Support for Python 3.6, 3.7, and 3.8 was dropped in intermediate versions.
  • OpenSSL Dependency:

    • Version 2.9.2 deprecated OpenSSL 1.0.1 and worked with 1.1.1.
    • Version 49.0.0 requires OpenSSL 3.0.0 or later. Support for OpenSSL 1.1.x was removed in v47.0.0.
  • API Removals and Changes:

    • Numerous deprecated functions and modules have been removed across dozens of major versions. This includes unsafe or outdated algorithms like binary elliptic curves (removed in v47.0.0) and ciphers like CAST5, SEED, IDEA, and Blowfish (moved to a decrepit module and later removed).
    • Support for 32-bit Windows and x86_64 macOS has been removed in favor of 64-bit and arm64, respectively.
    • The dependency on asn1crypto was removed.

Recommendation:

This upgrade cannot be performed directly. It should be treated as a major project involving:

  1. Upgrading your runtime environment (Python, OpenSSL).
  2. Ensuring your build environment has a compatible Rust toolchain if you build from source.
  3. Performing a careful, incremental upgrade of cryptography (e.g., 2.x -> 3.x -> ...), addressing deprecation warnings and breaking changes at each major step.
  4. Thoroughly auditing your code for usage of removed APIs and replacing them with modern alternatives provided by the library.

Source: Cryptography Changelog

Notice 🤖: This content was augmented using artificial intelligence. AI-generated content may contain errors and should be reviewed for accuracy before use.

@snyk-io

snyk-io Bot commented Aug 4, 2026

Copy link
Copy Markdown
Author

Snyk checks have failed. 1 issues have been found so far.

Status Scan Engine Critical High Medium Low Total (1)
Open Source Security 0 1 0 0 1 issues
Licenses 0 0 0 0 0 issues

💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants