unsafe-libyaml unaligned write of u64 on 32-bit and 16-bit platforms
Key facts
- Attack vector
- —
- Privileges required
- —
- User interaction
- —
- Attack complexity
- —
- Impact type
- —
- Confidentiality · integrity · availability
- —
- Fix status
- Fixed
No CVSS vector from any source. Fix status from GitHub.
Summary
Affected versions allocate memory using the alignment of `usize` and write data to it of type `u64`, without using `core::ptr::write_unaligned`. In platforms with sub-64bit alignment for `usize` (including wasm32 and x86) these writes are insufficiently aligned some of the time. If using an ordinary optimized standard library, the bug exhibits Undefined Behavior so may or may not behave in any sensible way, depending on optimization settings and hardware and other things. If using a Rust standard library built with debug assertions enabled, the bug manifests deterministically in a crash (non-unwinding panic) saying _"ptr::write requires that the pointer argument is aligned and non-null"_. No 64-bit platform is impacted by the bug. The flaw was corrected by allocating with adequately high alignment on all platforms.
Why it matters now
SSVC decision points
Not available: CISA has not published SSVC decision points for this record.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| — | unsafe-libyaml (crates.io) | before 0.2.10 | 0.2.10 | Patch available | GHSA-r24f-hg58-vfrw |
- unsafe-libyaml (crates.io) Vendor— Affected before 0.2.10 Fixed in 0.2.10 Patch available GHSA-r24f-hg58-vfrw
Remediation
- Fix · GHSA-r24f-hg58-vfrw unsafe-libyaml (crates.io) Fixed in 0.2.10 Advisory →
Timeline
- 2026-10-03 Threatist record created from GHSA-r24f-hg58-vfrw
References
Sources
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences