# CVE-2026-71847: Ruby JSON: JSON::ResumableParser\#partial\_value dereferences a freed input buffer and crashes on truncated duplicate-key streams

- Priority: **Prioritise**
- Reason: Severe, CVSS 8.7 (CVE.org); no exploitation reported by the 5 checked sources; EPSS 0% (FIRST, 04-12-2026)
- Next step: Check applicability: affected before 2.21.2 (CNA); fix release not confirmed
- Status: published
- Published: 2026-08-07 · Modified: 2026-08-07
- Aliases: UBUNTU-CVE-2026-71847, DEBIAN-CVE-2026-71847, CGA-5934-788f-cr4q, CGA-6frg-79hw-j43g, CGA-7r8q-hh6x-w8h4, CGA-9cfg-5xx3-3wj6, CGA-fv27-whww-xrqq, CGA-gw6x-m88c-jhwj, CGA-p74v-5xqm-gwmq, CGA-pg56-58h3-rx8m, CGA-q2w4-qg3j-rcg8, CGA-294w-rvhj-v8xf, CGA-5722-v55j-jfmg, CGA-6g87-w3vw-pj25, CGA-8m2w-p9xj-cfrv, CGA-957f-2jgg-v2xf, CGA-cfg3-299q-325h, CGA-ch3w-8pxq-pgw3, CGA-gf8v-mv2x-9rx8, CGA-jcwh-j7vm-xjwj, CGA-jf5p-24wc-f797, CGA-p5c2-39jm-6c8f, GHSA-9hj4-r449-hfvc, CGA-r257-85fc-4p2c
- Record: https://cvemate.com/vulnerability/CVE-2026-71847 · JSON: https://cvemate.com/vulnerability/CVE-2026-71847/json

## Description

```text
Ruby JSON is a JSON implementation for Ruby. From 2.20.0 until 2.21.2, Ruby's JSON native C extension clears the consumed JSON::ResumableParser input buffer but leaves state.start, state.cursor, and state.end pointing into released storage. When partial_value reconstructs an incomplete object containing duplicate keys, the duplicate-key warning path calls cursor_position, which dereferences those stale pointers. This results in a heap-use-after-free and can terminate the Ruby process. An attacker who can supply JSON stream data to an application using JSON::ResumableParser may cause process termination when the application calls partial_value on incomplete attacker-controlled input containing duplicate object keys. This issue has been fixed in version 2.21.2.
```

## Signals

- CVSS: 8.7 high (v4.0, CVE.org) CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N
- EPSS: 0.385%, percentile 34.753%, as of 2026-12-04
- Known exploited (KEV): CISA not listed, ENISA not listed, CIRCL not listed
- Ransomware use: none recorded
- Public exploits: 0

## Affected

- chainguard cinc-auditor (Chainguard): \< 7.1.7-r7 \| \< 7.1.7-r6
- chainguard logstash-9.5 (Chainguard): \< 9.5.1-r3
- chainguard logstash-9.5-iamguarded-compat (Chainguard): \< 9.5.1-r3
- chainguard logstash-fips-9.5 (Chainguard): \< 9.5.0-r2
- chainguard logstash-fips-9.5-iamguarded-compat (Chainguard): \< 9.5.0-r2
- chainguard pact-broker-docker (Chainguard): \< 2.142.0.2.120.0-r1
- chainguard pact-broker-docker-fips (Chainguard): \< 2.142.0.2.120.0-r1
- chainguard ruby3.2-rails-8.1 (Chainguard): \< 8.1.3.1-r1
- chainguard ruby3.3-rails-8.1 (Chainguard): \< 8.1.3.1-r1
- chainguard ruby3.4-rails-8.1 (Chainguard): \< 8.1.3.1-r1
- wolfi cinc-auditor (Wolfi): \< 7.1.7-r7 \| \< 7.1.7-r6
- wolfi ruby3.2-rails-8.1 (Wolfi): \< 8.1.3.1-r1
- wolfi ruby3.3-rails-8.1 (Wolfi): \< 8.1.3.1-r1
- wolfi ruby3.4-rails-8.1 (Wolfi): \< 8.1.3.1-r1
- debian ruby-json (Debian): All versions (No fix recorded) \| \< 2.21.2+dfsg-1
- ubuntu ruby-json (Ubuntu): All versions (No fix recorded)
- RubyGems json (RubyGems): ≥ 2.20.0, \< 2.21.2
- ruby json: ≥ 2.20.0, \< 2.21.2

## References

- <https://github.com/ruby/json/security/advisories/GHSA-9hj4-r449-hfvc>
- <https://ubuntu.com/security/CVE-2026-71847>
- <https://www.cve.org/CVERecord?id=CVE-2026-71847>
- <https://security-tracker.debian.org/tracker/CVE-2026-71847>
- <https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/71xxx/CVE-2026-71847.json>
- <https://nvd.nist.gov/vuln/detail/CVE-2026-71847>
- <https://github.com/ruby/json>

---

Data as of 2026-12-05T03:52:25.242Z. The priority label is CveMate's own model from public evidence, not an official rating, and it knows nothing about your assets. How labels are decided: https://cvemate.com/faq#priority
