# GHSA-24CH-F2G6-9HHH: msgpack5: Deeply nested input can exhaust the decoder stack

- Database: GitHub
- Severity: medium (stated by ghsa, no CVSS score)
- Published: 2026-10-08
- Modified: 2026-10-08

## Tracked as

- [CVE-2026-107298](https://cve.now/CVE-2026-107298.md): msgpack5: Deeply nested input can exhaust the decoder stack

## Affected versions

- msgpack5 (npm): fixed in 6.1.0

## Description

### Impact

The decoder has no nesting-depth limit for arrays and maps. An attacker who can provide MessagePack input can use deeply nested containers to exhaust the JavaScript call stack and interrupt the process or request handler.

### Patches

The decoder now limits nesting depth to 100 by default and throws `Maximum decode depth exceeded`. Applications can configure the limit with the `maxDepth` option.

### Workarounds

Reject deeply nested input before decoding, isolate decoding in a worker, or enforce a trusted schema with a bounded nesting depth.

## References

- https://github.com/mcollina/msgpack5/security/advisories/GHSA-24ch-f2g6-9hhh
- https://github.com/mcollina/msgpack5/commit/1e2b5874e555dd7c99417f64788a03b0590bb102
- https://github.com/mcollina/msgpack5
- https://github.com/mcollina/msgpack5/releases/tag/v6.1.0

Page: https://cve.now/GHSA-24CH-F2G6-9HHH

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