Vulnerability · Published Nov 24, 2020 · Assigned by GitHub_M

CVE-2020-26235Segmentation fault in Rust time crate

Medium 5.3

In plain English

A medium-severity null pointer dereference in time from time-rs. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 2.0% (higher than 80% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.

Severity (CVSS 3.1)5.3Medium
Exploit odds (30 days)2.0%top 19.6% of all CVEs
Exploited in the wildNo reportsnot in CISA KEV
Attack toolingNoneno public tooling known

Official description

In Rust time crate from version 0.2.7 and before version 0.2.23, unix-like operating systems may segfault due to dereferencing a dangling pointer in specific circumstances. This requires the user to set any environment variable in a different thread than the affected functions. The affected functions are time::UtcOffset::local_offset_at, time::UtcOffset::try_local_offset_at, time::UtcOffset::current_local_offset, time::UtcOffset::try_current_local_offset, time::OffsetDateTime::now_local and time::OffsetDateTime::try_now_local. Non-Unix targets are unaffected. This includes Windows and wasm. The issue was introduced in version 0.2.7 and fixed in version 0.2.23.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Alpine:v3.20newsboat2.30.1-r0ALPINE-CVE-2020-26235
Alpine:v3.21newsboat2.30.1-r0ALPINE-CVE-2020-26235
Alpine:v3.22newsboat2.30.1-r0ALPINE-CVE-2020-26235
Alpine:v3.23newsboat2.30.1-r0ALPINE-CVE-2020-26235
Alpine:v3.24newsboat2.30.1-r0ALPINE-CVE-2020-26235
Ubuntu:22.04:LTSrust-timeno fix listedUBUNTU-CVE-2020-26235
Ubuntu:24.04:LTSrust-timeno fix listedUBUNTU-CVE-2020-26235
Ubuntu:25.10rust-timeno fix listedUBUNTU-CVE-2020-26235
Ubuntu:26.04:LTSrust-timeno fix listedUBUNTU-CVE-2020-26235
Ubuntu:26.10rust-timeno fix listedUBUNTU-CVE-2020-26235

Affected products (as reported)

VendorProductVersions
time-rs time >= 0.2.7, <0.2.23

Weakness: CWE-476 · Vector: CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:N/I:N/A:H

References