Advisory

RUSTSEC-2021-0016

Also known as: CVE-2021-26952, GHSA-9f5r-vqm5-m342

Summary

IoReader::read(): user-provided Read on uninitialized buffer may cause UB

Details

Affected versions of this crate passes an uninitialized buffer to a user-provided Read implementation.

Arbitrary Read implementations can read from the uninitialized buffer (memory exposure) and also can return incorrect number of bytes written to the buffer.
Reading from uninitialized memory produces undefined values that can quickly invoke undefined behavior.

The flaw was fixed in commit 599313b by zero-initializing the buffer (via self.buf.resize(len, 0)) before passing it to Read.

Severity

High Basis: CVSS v3 score 7.5, vector CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N

Dates

Published
2021-01-26 12:00 UTC
Modified
2023-11-08 04:05 UTC

Affected packages and fixes

ms3d

crates.io · All systems

Affected

  • introduced 0.0.0-0, fixed 0.1.3 (semver)

Fixed versions

0.1.3

Fix

  • Fixed version 0.1.3
    cargo update -p ms3d --precise 0.1.3

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: RustSec Advisory Database · CC0-1.0

Sources & licences