# RUSTSEC-2026-0127: Integer overflow in `array::ReadWrite::new()` leading to potential memory corruption

- Severity: not scored yet
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Published: 2026-05-02T12:00:00.000Z
- Modified: 2026-05-13T12:30:54.055Z

## Description

In `array::ReadWrite::new()` (line 83 of `accessor/src/array.rs`),
`let bytes = mem::size_of::<T>() * len` can overflow `usize` when `len` is
very large. In release mode, this silently wraps, potentially making
`bytes = 0`. The mapper then maps with 0 bytes, and subsequent accesses
(e.g. `read_volatile_at`) lead to undefined behavior or memory corruption.

Note: `array::ReadWrite::new()` itself is `unsafe`, so direct triggering
requires an `unsafe` block. However, the integer overflow violates the
implicit safety contract expected by callers and can lead to memory
corruption downstream.

(As written by RustSec Advisory Database.)

## Affected

- accessor (crates.io): from 0.0.0-0

## References

- <https://crates.io/crates/accessor> (package)
- <https://rustsec.org/advisories/RUSTSEC-2026-0127.html> (advisory)
- <https://github.com/toku-sa-n/accessor/issues/49> (report)

## Sources

- RustSec Advisory Database: [RUSTSEC-2026-0127](https://rustsec.org/advisories/RUSTSEC-2026-0127.html), CC0-1.0, modified 2026-05-13

---

Page: https://cve.day/RUSTSEC-2026-0127 · Whole record: https://cve.day/RUSTSEC-2026-0127.json · Rebuilt by cve.day 2026-11-25T22:56:43.349Z
