Skip to main content
VulnerabilityPublished Updated

Sad rsa: Panics during RSA private-key construction, validation, or re-encoding

Affects sad-rsaSource GCVE Database

0

CVSS 5.3 Medium : upgrade to 0.10.4 when convenient.

Data as of 20 Nov 2026, 13:42 UTC

CVSS 3.1 base score
5.3Medium
How severe the flaw is on the 0–10 CVSS scale.
Patch
Available – fixed in 0.10.4
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L

What to do

Upgrade sad-rsa to 0.10.4.

Affected software

ProductAffectedFixed in
crates.iosad-rsapkg:cargo/sad-rsaOther threatsAffected
  • >=0.0.0-0 <0.10.4
Fixed in
  • 0.10.4

Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.

AI-suggested

Upgrade to sad-rsa version 0.10.4 or later, which includes fixes rejecting invalid factors and correct serialization handling. If upgrading is not possible, isolate key import, construction, CRT calculation, and serialization in a separate process and treat abnormal exits as failures. Alternatively, use Rust's catch_unwind to catch panics during these operations to prevent process termination.

Description

The Sad RSA vulnerability involves panics during RSA private-key construction, validation, or serialization in the Rust 'sad-rsa' crate. These panics occur when invalid factors such as 0, 1, or even numbers are supplied, or when re-encoding certain valid keys with uneven prime sizes. This can cause a worker thread or the entire process to abort if built with panic = "abort". The issue affects versions prior to 0.10.4 and does not impact public-key parsing.

References

Community reviews

Loading reviews…