Advisory Database
  • Advisories
  • Dependency Scanning
  1. cargo
  2. ›
  3. time
  4. ›
  5. CVE-2020-26235

CVE-2020-26235: Segmentation fault in time

August 25, 2021 (updated June 10, 2024)

Unix-like operating systems may segfault due to dereferencing a dangling pointer in specific circumstances. This requires an environment variable to be set in a different thread than the affected functions. This may occur without the user’s knowledge, notably in a third-party library.

The affected functions from time 0.2.7 through 0.2.22 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
  • time::OffsetDateTime::try_now_local

The affected functions in time 0.1 (all versions) are:

  • at
  • at_utc
  • now

Non-Unix targets (including Windows and wasm) are unaffected.

References

  • crates.io/crates/time/0.2.23
  • github.com/advisories/GHSA-wcg3-cvx6-7396
  • github.com/time-rs/time
  • github.com/time-rs/time/issues/293
  • github.com/time-rs/time/security/advisories/GHSA-wcg3-cvx6-7396
  • nvd.nist.gov/vuln/detail/CVE-2020-26235
  • rustsec.org/advisories/RUSTSEC-2020-0071.html

Code Behaviors & Features

Detect and mitigate CVE-2020-26235 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Dependency Scanning using SBOM also detects vulnerabilities from proprietary advisories that this site does not include. Learn more about Dependency Scanning using SBOM →

Affected versions

All versions starting from 0.1.0 before 0.2.23, all versions starting from 0.2.7 before 0.2.23

Fixed versions

  • 0.2.23
  • 0.2.23

Solution

Upgrade to versions 0.2.23, 0.2.23 or above.

Impact 6.2 MEDIUM

CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H

Learn more about CVSS

Weakness

  • CWE-476: NULL Pointer Dereference

Source file

cargo/time/CVE-2020-26235.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Sun, 08 Nov 2026 00:17:27 +0000.