# GHSA-GCX5-HXJ7-GPQQ: msgpack5: Quadratic parsing in the streaming decoder

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

## Tracked as

- [CVE-2026-107297](https://cve.now/CVE-2026-107297.md): msgpack5: Quadratic parsing in the streaming decoder

## Affected versions

- msgpack5 (npm): fixed in 6.1.0

## Description

### Impact

The streaming decoder reparses an incomplete container from the beginning whenever another chunk arrives. A remote peer can split one valid MessagePack value across many small chunks, causing quadratic CPU usage and blocking the event loop.

### Patches

The decoder now preserves incremental container state so completed elements are not parsed again when more input arrives.

### Workarounds

Buffer each complete MessagePack value before decoding it, or limit the number of chunks accepted for a single value.

## References

- https://github.com/mcollina/msgpack5/security/advisories/GHSA-gcx5-hxj7-gpqq
- https://github.com/mcollina/msgpack5/commit/e4827641d3105e295cbbd56e9c5389978547eab4
- https://github.com/mcollina/msgpack5
- https://github.com/mcollina/msgpack5/releases/tag/v6.1.0

Page: https://cve.now/GHSA-GCX5-HXJ7-GPQQ

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