Skip to content
OpenAdvisories
Unscored RUSTSEC-2026-0397

`OutBuffer::around_pos` exposes uninitialized memory

Published Oct 16, 2026 · Updated Nov 2, 2026 · Assigned by RUSTSEC

Description

`OutBuffer::around_pos` accepted a position past the initialized length of a
`Vec<u8>`. The next streaming call then marked everything before the
position as initialized, so safe code could read stale heap memory between
the vector's previous length and that position.

The flaw was corrected by zero-filling that gap.

Affected packages

EcosystemPackageAffectedFixedRecord
crates.io zstd-safe >= 4.0.0, < 7.4.0 · >= 8.0.0-0, < 8.2.0 7.4.0, 8.2.0 RUSTSEC-2026-0397

References