msgpack5
Ecosystem: npm
Downloads: 675.26 K
- 0CriticalAffects 0 versions
- 2HighAffects 2 versions
- 0MediumAffects 0 versions
- 5ModerateAffects 7 versions
- 1LowAffects 1 version
- Critical0 (0.0%)
- High2 (25.0%)
- Medium0 (0.0%)
- Moderate5 (62.5%)
- Low1 (12.5%)
Monthly breakdown
- Critical
- High
- Medium
- Moderate
- Low
- 7 vulnerabilities
- Critical: 0
- High: 2
- Medium: 0
- Moderate: 4
- Low: 1
- 1 vulnerabilities
- Critical: 0
- High: 0
- Medium: 0
- Moderate: 1
- Low: 0
Vulnerabilities (8)
Known vulnerabilities affecting msgpack5, based on data from OSV.
| ID | Severity | Summary | Affected versions | Published | Source |
|---|---|---|---|---|---|
| GHSA-24ch-f2g6-9hhh | Moderate | msgpack5: Deeply nested input can exhaust the decoder stack### 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. |
| GitHub (opens in a new tab) | |
| GHSA-26wq-p25c-j6fv | Moderate | msgpack5: Reserved byte can cause unbounded stream buffering### Impact The reserved MessagePack byte `0xc1` is incorrectly treated as incomplete input. When it appears at the start of a decoder stream, all subsequent data is retained while the decoder waits for bytes that can never make the value valid, allowing memory exhaustion. ### Patches The decoder now rejects `0xc1` as invalid input. Streaming decoders release buffered input and stop after unrecoverable decoding errors. ### Workarounds Reject `0xc1` before streaming input to msgpack5, and enforce stream byte and time limits. |
| GitHub (opens in a new tab) | |
| GHSA-5x5g-h9x8-2fh9 | High | msgpack5: Many buffered values can exhaust the streaming decoder stack### Impact The streaming decoder recursively invokes itself for every complete value remaining in a chunk. A single chunk containing many small valid MessagePack values can exhaust the JavaScript call stack and interrupt the process or stream. ### Patches The streaming decoder now drains concatenated values iteratively with constant call-stack depth. ### Workarounds Limit the number of MessagePack values accepted in one chunk, or split large batches before passing them to the decoder stream. |
| GitHub (opens in a new tab) | |
| GHSA-8f34-f56x-9xph | High | msgpack5: Truncated map32 headers throw an unexpected error### Impact A truncated `map32` header causes an out-of-bounds buffer read and throws `RangeError` instead of `IncompleteBufferError`. Applications that rely on `IncompleteBufferError` to wait for additional bytes may terminate a request, stream, or worker unexpectedly. No adjacent memory is disclosed because the buffer implementation checks bounds. ### Patches The decoder now validates the complete five-byte `map32` header before reading its length and reports truncated input as `IncompleteBufferError`. ### Workarounds Require at least five bytes before decoding a value beginning with `0x |
| GitHub (opens in a new tab) | |
| GHSA-8hq7-ggx2-cc6m | Moderate | msgpack5: Partial options disable prototype protection### Impact Passing an empty or partial options object disables the default `protoAction: 'error'` protection. A map containing a `__proto__` key can then replace the prototype of the decoded object, potentially changing inherited properties or causing unexpected behavior in downstream code. Only the decoded object's prototype is affected; this does not modify `Object.prototype` globally. ### Patches Options are now merged with secure defaults without modifying the caller's object. Unsupported `protoAction` values are rejected. ### Workarounds Explicitly set `protoAction: 'error'` wheneve |
| GitHub (opens in a new tab) | |
| GHSA-gcx5-hxj7-gpqq | Moderate | msgpack5: Quadratic parsing in the streaming decoder### 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. |
| GitHub (opens in a new tab) | |
| GHSA-qw35-55vc-rhgj | Low | msgpack5: Decoding negative int64 values mutates the input buffer### Impact Decoding a negative signed 64-bit integer modifies the corresponding bytes in the caller-provided input buffer. Applications that retain or reuse encoded input for integrity checks, logging, or subsequent processing may observe silently corrupted data. Positive integers and other MessagePack value types are not affected. ### Patches The decoder now computes signed 64-bit values without writing to the input buffer. ### Workarounds Copy untrusted MessagePack input before decoding it, or do not retain or reuse input buffers after decoding. |
| GitHub (opens in a new tab) | |
| GHSA-gmjw-49p4-pcfm | Moderate | Prototype poisoning### Impact The issue is as follows: when `msgpack5` decodes a map containing a key `"__proto__"`, it assigns the decoded value to `__proto__`. As you are no doubt aware, `Object.prototype.__proto__` is an accessor property for the receiver's prototype. If the value corresponding to the key `__proto__` decodes to an object or `null`, `msgpack5` sets the decoded object's prototype to that value. An attacker who can submit crafted MessagePack data to a service can use this to produce values that appear to be of other types; may have unexpected prototype properties and methods (for examp |
| GitHub (opens in a new tab) |
- GHSA-24ch-f2g6-9hhhModeratemsgpack5: Deeply nested input can exhaust the decoder stack
< 6.1.0
### 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.
CVE: CVE-2026-107298
- GHSA-26wq-p25c-j6fvModeratemsgpack5: Reserved byte can cause unbounded stream buffering
< 6.1.0
### Impact The reserved MessagePack byte `0xc1` is incorrectly treated as incomplete input. When it appears at the start of a decoder stream, all subsequent data is retained while the decoder waits for bytes that can never make the value valid, allowing memory exhaustion. ### Patches The decoder now rejects `0xc1` as invalid input. Streaming decoders release buffered input and stop after unrecoverable decoding errors. ### Workarounds Reject `0xc1` before streaming input to msgpack5, and enforce stream byte and time limits.
CVE: CVE-2026-107299
- GHSA-5x5g-h9x8-2fh9Highmsgpack5: Many buffered values can exhaust the streaming decoder stack
< 6.1.0
### Impact The streaming decoder recursively invokes itself for every complete value remaining in a chunk. A single chunk containing many small valid MessagePack values can exhaust the JavaScript call stack and interrupt the process or stream. ### Patches The streaming decoder now drains concatenated values iteratively with constant call-stack depth. ### Workarounds Limit the number of MessagePack values accepted in one chunk, or split large batches before passing them to the decoder stream.
CVE: CVE-2026-107300
- GHSA-8f34-f56x-9xphHighmsgpack5: Truncated map32 headers throw an unexpected error
>= 4.1.0, < 6.1.0
### Impact A truncated `map32` header causes an out-of-bounds buffer read and throws `RangeError` instead of `IncompleteBufferError`. Applications that rely on `IncompleteBufferError` to wait for additional bytes may terminate a request, stream, or worker unexpectedly. No adjacent memory is disclosed because the buffer implementation checks bounds. ### Patches The decoder now validates the complete five-byte `map32` header before reading its length and reports truncated input as `IncompleteBufferError`. ### Workarounds Require at least five bytes before decoding a value beginning with `0x
CVE: CVE-2026-107302
- GHSA-8hq7-ggx2-cc6mModeratemsgpack5: Partial options disable prototype protection
< 6.1.0
### Impact Passing an empty or partial options object disables the default `protoAction: 'error'` protection. A map containing a `__proto__` key can then replace the prototype of the decoded object, potentially changing inherited properties or causing unexpected behavior in downstream code. Only the decoded object's prototype is affected; this does not modify `Object.prototype` globally. ### Patches Options are now merged with secure defaults without modifying the caller's object. Unsupported `protoAction` values are rejected. ### Workarounds Explicitly set `protoAction: 'error'` wheneve
CVE: CVE-2026-107301
- GHSA-gcx5-hxj7-gpqqModeratemsgpack5: Quadratic parsing in the streaming decoder
< 6.1.0
### 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.
CVE: CVE-2026-107297
- GHSA-qw35-55vc-rhgjLowmsgpack5: Decoding negative int64 values mutates the input buffer
< 6.1.0
### Impact Decoding a negative signed 64-bit integer modifies the corresponding bytes in the caller-provided input buffer. Applications that retain or reuse encoded input for integrity checks, logging, or subsequent processing may observe silently corrupted data. Positive integers and other MessagePack value types are not affected. ### Patches The decoder now computes signed 64-bit values without writing to the input buffer. ### Workarounds Copy untrusted MessagePack input before decoding it, or do not retain or reuse input buffers after decoding.
CVE: CVE-2026-107296
- GHSA-gmjw-49p4-pcfmModeratePrototype poisoning
< 3.6.1>= 4.0.0, < 4.5.1- +1 more
Affected versions:< 3.6.1>= 4.0.0, < 4.5.1>= 5.0.0, < 5.2.1
### Impact The issue is as follows: when `msgpack5` decodes a map containing a key `"__proto__"`, it assigns the decoded value to `__proto__`. As you are no doubt aware, `Object.prototype.__proto__` is an accessor property for the receiver's prototype. If the value corresponding to the key `__proto__` decodes to an object or `null`, `msgpack5` sets the decoded object's prototype to that value. An attacker who can submit crafted MessagePack data to a service can use this to produce values that appear to be of other types; may have unexpected prototype properties and methods (for examp
CVE: CVE-2021-21368