
Cloud Vulnerability DB
A community-led vulnerabilities database
The vulnerability (GHSA-fq33-vmhv-48xh) affects the ntru-rs Rust crate, versions 0.4.3 through 0.5.6. It was discovered on March 22, 2023, and officially published to the GitHub Advisory Database on April 7, 2023. The issue involves unsound Foreign Function Interface (FFI) implementation where incorrect API usage can lead to writes beyond allocated memory areas (GitHub Advisory, RustSec Advisory).
The vulnerability manifests when using specific API calls in the ntru crate, particularly when exporting public keys. The problematic code pattern involves calling export() on a public key with default parameters: kp.get_public().export(Default::default()). When compiled with debug assertions, this triggers an 'attempt to subtract with overflow' panic before undefined behavior occurs. Additionally, other misuses, such as utilizing EncParams from a different key, can directly lead to undefined behavior (GitHub Issue, RustSec Advisory).
The vulnerability can result in memory corruption and buffer overflow issues, potentially leading to undefined behavior in affected applications. This is particularly concerning as it occurs in what should be safe Rust code, potentially compromising memory safety guarantees (RustSec Advisory).
As of the latest reports, no patched versions are available for this vulnerability. Users of the ntru crate versions 0.4.3 through 0.5.6 should exercise caution when using the export functionality and avoid using default parameters in key export operations (GitHub Advisory).
Source: This report was generated using AI
Free Vulnerability Assessment
Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.
Get a personalized demo
"Best User Experience I have ever seen, provides full visibility to cloud workloads."
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
"We know that if Wiz identifies something as critical, it actually is."