PT-2020-17555 · Rust · Ordered-Float Crate
Published
2020-12-06
·
Updated
2021-08-25
·
CVE-2020-35923
CVSS v3.1
5.5
Medium
| Vector | AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H |
Name of the Vulnerable Software and Affected Versions
ordered-float crate versions prior to 1.1.1
ordered-float crate versions 2.x prior to 2.0.1
Description
An issue was discovered where a NotNan value can contain a NaN after using assignment operators such as
NotNan::add assign or NotNan::mul assign. This could cause undefined behavior in safe code due to the NotNan::cmp method containing internal unsafe code that assumes the value is never NaN. The issue could also cause undefined behavior in third-party unsafe code and logic errors in safe code. The flaw was partially mitigated in version 0.4.0 by panicking if the assigned value is NaN, but code using the NotNan value during unwinding or after catching the panic could still observe the invalid value and trigger undefined behavior.Recommendations
For ordered-float crate versions prior to 1.1.1, update to version 1.1.1 or later to fully correct the flaw.
For ordered-float crate versions 2.x prior to 2.0.1, update to version 2.0.1 or later to fully correct the flaw.
Exploit
Fix
Use After Free
Found an issue in the description? Have something to add? Feel free to write us 👾
Related Identifiers
Affected Products
Ordered-Float Crate