# CVE-2026-54592: Oj: Stack Buffer Overflow in Oj::Doc\#each\_child via Deeply Nested Input

- Priority: **Prioritise**
- Reason: Severe, CVSS 7.5 (CVE.org); no exploitation reported by the 5 checked sources; EPSS 0% (FIRST, 04-12-2026)
- Next step: Check applicability: affected before 3.17.3 (CNA); fix release not confirmed
- Status: published
- Published: 2026-06-30 · Modified: 2026-07-01
- Aliases: UBUNTU-CVE-2026-54592, DEBIAN-CVE-2026-54592, CGA-29rf-v244-hf86, CGA-2g53-8mm8-f4j2, CGA-32h6-9vcc-279f, CGA-3rwg-r4r6-jc5c, CGA-83xj-xvpm-m436, CGA-983r-gwh3-g33g, CGA-c9hr-56r4-69v4, CGA-frqq-8fqf-qh6q, CGA-hw4w-wr7h-h89f, CGA-jfq4-2c57-xjww, CGA-mq53-34j4-pgvh, CGA-qc8f-5m73-p53c, CGA-qcm3-fh6c-5f6f, CGA-qr4w-jm5r-8vpw, CGA-r8qq-mpvv-9qfc, CGA-wc5x-p7mv-c4mp, CGA-238r-6772-pjjm, CGA-2gm8-65q7-4g97, CGA-2qpx-p4gw-38m6, CGA-3wgr-7jfc-q5g5, CGA-45cw-2fwq-8q3g, CGA-46w8-ph9f-3c38, CGA-47xx-j66h-f7mc, CGA-4fmx-2xxr-5346, CGA-4fqc-m3q8-fw9v, CGA-5qvg-9c6v-h8jm, CGA-64cp-vg5v-2h24, CGA-65jh-prfp-pvqp, CGA-6gmr-4m73-r89r, CGA-6rjr-4w9q-3wwx, CGA-6wjg-962x-q5rf, CGA-72rj-c375-6wxh, CGA-864g-7gcr-5455, CGA-8c65-w2hx-xgcw, CGA-8hwx-6cjf-vw3g, CGA-9vvj-fmmc-qccw, CGA-cj89-prvx-cfmw, CGA-cjpq-p2vj-whjw, CGA-crqc-xwg3-fvwh, CGA-f2mw-g6hx-hf6f, CGA-fxw5-fcq3-2f7w, CGA-gfgq-4r57-4pc7, CGA-h6v8-4m56-9q4m, CGA-hqc4-88r7-c48v, CGA-jqhr-m9c6-grhr, CGA-jrh9-pmj8-f6mw, CGA-jwhv-93qr-5ff6, CGA-mq35-gj8v-8h5x, CGA-p4hq-qmjw-9pq3, CGA-pjr8-92jf-59rh, GHSA-3m6q-jj5j-38c9, CGA-q7f4-4qfv-6cfm, CGA-rf96-qmx7-h3w5, CGA-rwvp-rvh2-qf93, CGA-v8f2-7x3c-c3j9, CGA-vvc8-mj65-fgpg, CGA-w45c-f756-7j88, CGA-wgqr-3734-wpfj, CGA-x5h4-gxf4-92fx, CGA-xjhc-5gpv-xw5x, CGA-xmxp-7gwm-7mf7
- Record: https://cvemate.com/vulnerability/CVE-2026-54592 · JSON: https://cvemate.com/vulnerability/CVE-2026-54592/json

## Description

```text
Oj (Optimized JSON) is a JSON parser and Object marshaller packaged as a Ruby gem. In versions prior to 3.17.3, Oj::Doc#each_child, when invoked recursively over a deeply nested JSON document, overflows a fixed-size stack buffer and aborts the process, leading to DoS.  In a two-step chain in ext/oj/fast.c, doc_each_child increments doc->where past the where_path[MAX_STACK = 100] array with no bounds check and never restores it (the doc->where-- is missing), so calling each_child recursively from inside the yield block drives doc->where beyond the array. On the next entry  the function copies the path into the 800-byte stack-local buffer save_path[MAX_STACK]  using wlen = doc->where - doc->where_path, so when the previous recursive call left doc->where past where_path[100] the wlen exceeds MAX_STACK and  the memcpy overflows save_path on the C stack; because the Oj::Doc parser imposes no JSON nesting-depth limit (relying on a C-stack pressure check), deeply nested attacker input reaches this path. This issue has been fixed in version 3.17.3.
```

## Signals

- CVSS: 7.5 high (v3.1, CVE.org) CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
- EPSS: 0.328%, percentile 27.865%, 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 (first 20 of 38)

- chainguard gitlab-rails-ce-18.1 (Chainguard): All versions (No fix recorded)
- chainguard gitlab-rails-ce-18.5 (Chainguard): All versions (No fix recorded)
- chainguard gitlab-rails-ce-18.6 (Chainguard): All versions (No fix recorded)
- chainguard gitlab-rails-ce-18.7 (Chainguard): All versions (No fix recorded)
- chainguard gitlab-rails-ce-18.8 (Chainguard): All versions (No fix recorded)
- chainguard gitlab-rails-ce-18.9 (Chainguard): All versions (No fix recorded)
- chainguard gitlab-rails-ce-fips-18.1 (Chainguard): All versions (No fix recorded)
- chainguard gitlab-rails-ce-fips-18.5 (Chainguard): All versions (No fix recorded)
- chainguard gitlab-rails-ce-fips-18.6 (Chainguard): All versions (No fix recorded)
- chainguard gitlab-rails-ce-fips-18.7 (Chainguard): All versions (No fix recorded)
- chainguard gitlab-rails-ce-fips-18.8 (Chainguard): All versions (No fix recorded)
- chainguard gitlab-rails-ce-fips-18.9 (Chainguard): All versions (No fix recorded)
- chainguard ruby3.2-fluentd-kubernetes-daemonset-1.16-kinesis (Chainguard): \< 1.16.11.1.0-r3
- chainguard ruby3.2-fluentd-kubernetes-daemonset-1.17-kinesis (Chainguard): \< 1.17.1.1.2-r10
- chainguard ruby3.2-fluentd-kubernetes-daemonset-1.18-kinesis (Chainguard): \< 1.18.0.1.5-r3
- chainguard ruby3.2-fluentd-kubernetes-daemonset-1.19-kinesis (Chainguard): \< 1.19.2.1.1-r5
- chainguard ruby3.2-kube-logging-operator-fluentd-outputs (Chainguard): \< 6.7.0-r4
- chainguard ruby3.3-fluentd-kubernetes-daemonset-1.16-kinesis (Chainguard): \< 1.16.11.1.0-r3
- chainguard ruby3.3-fluentd-kubernetes-daemonset-1.17-kinesis (Chainguard): \< 1.17.1.1.2-r9
- chainguard ruby3.3-fluentd-kubernetes-daemonset-1.18-kinesis (Chainguard): \< 1.18.0.1.5-r4

## References

- <https://github.com/ohler55/oj/security/advisories/GHSA-3m6q-jj5j-38c9>
- <https://ubuntu.com/security/CVE-2026-54592>
- <https://www.cve.org/CVERecord?id=CVE-2026-54592>
- <https://security-tracker.debian.org/tracker/CVE-2026-54592>
- <https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/54xxx/CVE-2026-54592.json>
- <https://nvd.nist.gov/vuln/detail/CVE-2026-54592>
- <https://github.com/ohler55/oj>

---

Data as of 2026-12-05T04:10:42.580Z. 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
