Vulnerability DatabaseRUSTSEC-2024-0409

RUSTSEC-2024-0409
Rust vulnerability analysis and mitigation

Overview

RUSTSEC-2024-0409 affects PyO3 versions 0.23.0 through 0.23.2. The vulnerability is related to a soundness bug in compile configuration where the PYO3_CONFIG_FILE environment variable is not properly handled, leading to incorrect code generation. The issue was discovered and disclosed in December 2024, affecting Python bindings created with the affected PyO3 versions (PyO3 Issue).

Technical details

The vulnerability stems from a change in how the PYO3_CONFIG_FILE environment variable is read, where the code fails to emit the cargo:rerun-if-changed block for it. This causes wheels built in bulk for multiple Python interpreters to not rebuild properly, instead containing code configured for only the first interpreter built. This particularly impacts scenarios where multiple builds are performed in the same directory or when build caching is used (PyO3 Issue).

Impact

The bug results in wheels that are highly unstable and can fail in unpredictable ways. This has led to segmentation faults in projects like watchfiles and jiter, as well as unexpected errors in test suites of projects such as pydantic-core. Projects building single ABI3 wheels, like cryptography, are likely unaffected (PyO3 Issue).

Exploitability

The vulnerability is primarily triggered in build environments using maturin to build wheels for multiple Python interpreters (e.g., using commands like 'maturin build -i 3.8 3.9 3.10 3.11'). The issue manifests when building multiple versions in the same directory or when using build caching (PyO3 Issue).

Mitigation and workarounds

The issue has been fixed in PyO3 version 0.23.3. Users are advised to upgrade to this version immediately. The development team has indicated that versions 0.23.0 through 0.23.2 will be yanked from the repository (PyO3 Issue).

Additional resources


SourceThis report was generated using AI

Related Rust vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2026-46369HIGH7.5
  • Rust logoRust
  • nimiq-blockchain
NoYesAug 12, 2026
CVE-2026-73430MEDIUM5.3
  • Rust logoRust
  • russh
NoYesAug 12, 2026
CVE-2026-73429MEDIUM5.3
  • Rust logoRust
  • russh
NoYesAug 12, 2026
RUSTSEC-2026-0256NONEN/A
  • Rust logoRust
  • circular-buffer
NoYesAug 11, 2026
RUSTSEC-2026-0255NONEN/A
  • Rust logoRust
  • sized-chunks
NoNoAug 11, 2026

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management