# RUSTSEC-2024-0366: A specifically crafted Wasm file can cause the VM to consume excessive amounts of memory when compiling a contract

- Database: RustSec
- Published: 2024-08-27
- Modified: 2025-10-28

## Also published as

- [GHSA-75QH-GG76-P2W4](https://cve.now/GHSA-75QH-GG76-P2W4.md) (GitHub)
- [GO-2024-3101](https://cve.now/GO-2024-3101.md) (Go)

## Affected versions

- cosmwasm-vm (crates.io): fixed in 1.2.8; from 1.3.0, fixed in 1.3.4; from 1.4.0, fixed in 1.4.2; from 1.5.0, fixed in 1.5.1

## Description

A specifically crafted Wasm file can cause the VM to consume excessive amounts of memory when compiling a contract.
This can lead to high memory usage, slowdowns, potentially a crash and can poison a lock in the VM,
preventing any further interaction with contracts.

For more information, see [CWA-2023-004](https://github.com/CosmWasm/advisories/blob/main/CWAs/CWA-2023-004.md).

## References

- https://crates.io/crates/cosmwasm-vm
- https://rustsec.org/advisories/RUSTSEC-2024-0366.html
- https://github.com/CosmWasm/advisories/blob/main/CWAs/CWA-2023-004.md

Page: https://cve.now/RUSTSEC-2024-0366

Wrong or missing data? Send feedback: POST https://cve.now/api/v1/feedback (see https://cve.now/agents#feedback).
