# GHSA-GQMC-89G8-P25R: Excessive allocated memory on the host when guests don't have stdio

- Database: GitHub
- Severity: CVSS 5.9 (Medium)
- Published: 2026-10-02
- Modified: 2026-10-23

## Tracked as

- [CVE-2026-115381](https://cve.now/CVE-2026-115381.md): Wasmtime before 36.0.17, 37.0.0 before 48.0.4, and 49.0.0 before 49.0.2 Unbounded Host Memory Allocation via SinkOutputStream write-zeroes

## Affected versions

- wasmtime-wasi (crates.io): fixed in 36.0.17
- wasmtime-wasi (crates.io): from 37.0.0, fixed in 48.0.4
- wasmtime-wasi (crates.io): from 49.0.0, fixed in 49.0.2

## Description

### Impact

The `wasmtime-wasi` crate contained a bug where the `write-zeros` method on a specific type in the crate, `SinkOutputStream`, permitted an unlimited-size allocation on the host. This type is used by default for `WasiCtx`s that are created and represents a guest that doesn't actually print anything via stdout/stderr to the host. The `write-zeroes` method in the WASIp2 implementation for this type ended up not limiting the allocation made of a buffer-of-zeros to write.

This bug is related to GHSA-852m-cvvp-9p4w where the fixes applied for that advisory were intended to limit the size of host allocations, but the fix was incomplete for this specific stream and situation. Specifically the limitations previously allowed up to the size of the `check-write`-limit, but for `SinkOutputStream` the limit was previously unlimited.

This bug only affects embeddings which don't configure stdout/stderr streams. Configured streams have their own limits typically which would prevent this large allocation, but unconfigured streams use `SinkOutputStream` which allows an unlimited-size allocation.

### Patches

This issue has been fixed in Wasmtime 36.0.17, 48.0.4, and 49.0.2. All other previously published versions of Wasmtime are vulnerable and users are recommended to upgrade.

### Workarounds

Affected embeddings can work around this by specifying a custom implementation of `OutputStream` which returns a limited value from `check_write`. Embeddings can also fix this by updating a patch release, too.

## References

- https://github.com/bytecodealliance/wasmtime/security/advisories/GHSA-gqmc-89g8-p25r

Page: https://cve.now/GHSA-GQMC-89G8-P25R

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