Files
vuln-osv/data/crates.io/RUSTSEC-2026-0274.json
T

1 line
1.7 KiB
JSON

{"schema_version":"1.9.0","id":"RUSTSEC-2026-0274","published":"2026-08-04T12:00:00Z","modified":"2026-09-01T08:00:25.184913524Z","summary":"Double free / use-after-free in `ReadChunk::commit` when an element's `Drop` panics","details":"`ReadChunk::commit` and `ReadChunk::commit_all` drop the committed elements\nbefore advancing the consumer head. If an element's `Drop` panics during the\ndrop loop, `head` is never advanced, so the ring buffer still treats those slots\nas holding live elements. When the `RingBuffer` is later dropped (it walks\n`head..tail` and drops each slot), or a subsequent `read_chunk()` / `commit()`\ntouches the same slots, the already-dropped elements are dropped a second time —\na double free (CWE-415) / use-after-free (CWE-416) reachable from safe Rust.\n\n## Mitigation\n\nUpdate to 0.3.5 (0.3.x line) or 0.4.0. Note that 0.4.0 contains a behavior\nchange in `is_abandoned()`, so users on 0.3.x should prefer 0.3.5.","affected":[{"package":{"name":"rtrb","ecosystem":"crates.io","purl":"pkg:cargo/rtrb"},"ranges":[{"type":"SEMVER","events":[{"introduced":"0.0.0-0"},{"fixed":"0.3.5"},{"introduced":"0.4.0-0"},{"fixed":"0.4.0"}]}],"ecosystem_specific":{"affected_functions":null,"affects":{"arch":[],"functions":["rtrb::chunks::ReadChunk::commit","rtrb::chunks::ReadChunk::commit_all"],"os":[]}},"database_specific":{"categories":["memory-corruption"],"cvss":null,"informational":null,"source":"https://github.com/rustsec/advisory-db/blob/osv/crates/RUSTSEC-2026-0274.json"}}],"references":[{"type":"PACKAGE","url":"https://crates.io/crates/rtrb"},{"type":"ADVISORY","url":"https://rustsec.org/advisories/RUSTSEC-2026-0274.html"},{"type":"REPORT","url":"https://github.com/mgeier/rtrb/issues/185"}],"database_specific":{"license":"CC0-1.0"}}