Advisory Database
  • Advisories
  • Dependency Scanning
  1. cargo
  2. ›
  3. lexical
  4. ›
  5. GHSA-c2hm-mjxv-89r4

GHSA-c2hm-mjxv-89r4: Multiple soundness issues in lexical

September 4, 2023 (updated September 16, 2024)

lexical contains multiple soundness issues:

  1. Bytes::read() allows creating instances of types with invalid bit patterns
  2. BytesIter::read() advances iterators out of bounds
  3. The BytesIter trait has safety invariants but is public and not marked unsafe
  4. write_float() calls MaybeUninit::assume_init() on uninitialized data, which is is not allowed by the Rust abstract machine
  5. radix() calls MaybeUninit::assume_init() on uninitialized data, which is is not allowed by the Rust abstract machine

The crate also has some correctness issues.

References

  • github.com/Alexhuszagh/rust-lexical
  • github.com/advisories/GHSA-c2hm-mjxv-89r4
  • rustsec.org/advisories/RUSTSEC-2023-0055.html

Code Behaviors & Features

Detect and mitigate GHSA-c2hm-mjxv-89r4 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 7.0.0

Fixed versions

  • 7.0.0

Solution

Upgrade to version 7.0.0 or above.

Source file

cargo/lexical/GHSA-c2hm-mjxv-89r4.yml

Spotted a mistake? Edit the file on GitLab.

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

Page generated Wed, 14 May 2025 12:15:34 +0000.