NewApp Monitoring is liveSign up free
AgentbeamBeta
Open-source package vulnerability · Rust (crates.io)

CVE-2023-53156: transpose: Buffer overflow due to integer overflow

mediumCVSS 3.1 4.5GHSA-5gmm-6m36-r7jh

Given the function transpose::transpose: The safety check inputwidth inputheight == output.len() can fail due to inputwidth inputheight overflowing in such a way that it equals output.len(). As a result of failing the safety check, memory past the end of output is written to. This only occurs in release mode since panics on overflow in debug mode.

Published Apr 5, 2024 · Updated Jul 28, 2025

Affected packages

transpose

Ecosystem
Rust (crates.io)
Affected
>= 0.1.0, < 0.2.3
Fixed in
0.2.3
Check
cargo tree -i transpose

Advisory details

From the GitHub Advisory Database (CC BY 4.0).

Given the function transpose::transpose:

fn transpose<T: Copy>(input: &[T], output: &mut [T], input_width: usize, input_height: usize)

The safety check input_width * input_height == output.len() can fail due to input_width * input_height overflowing in such a way that it equals output.len(). As a result of failing the safety check, memory past the end of output is written to. This only occurs in release mode since * panics on overflow in debug mode.

Exploiting this issue requires the caller to pass input_width and input_height arguments such that multiplying them overflows, and the overflown result equals the lengths of input and output slices.

References

How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. No analysis has been written for this entry yet. Methodology