Ruby JSON: Out of Bound Write in parser when `allow_control_characters: true` is enabled
- CVE-2026-141523
- GHSA-cjpr-jw2g-fw99
- EUVD-2026-140723
Description
Ruby JSON is a JSON implementation for Ruby. From 2.18.0 until 2.18.2 and 2.19.3, JSON.parse can perform an out-of-bounds write when allow_control_characters is enabled and attacker-controlled invalid JSON contains sufficient padding before a backslash immediately followed by an ASCII control character. This malformed escape sequence can defeat the parser's bounds checks, potentially corrupting heap memory and more likely crashing the Ruby VM, which can cause denial of service in applications that parse untrusted input with the affected option. This issue is fixed in versions 2.18.2 and 2.19.3.
Text from the CVE.org record.
Recommendation
json
- If you run 2.19.xupdate to 2.19.3 or laterPatch update: breaking changes are unlikelyjson 2.19.3 on its registry (opens in a new tab)
- If you run 2.18.xupdate to 2.18.2 or laterPatch update: breaking changes are unlikelyjson 2.18.2 on its registry (opens in a new tab)
Taken from the version ranges the sources state. Check the vendor advisory: nothing is said about versions the ranges do not list. Breaking-change risk is read from the version numbers only.
Affected
ruby json
Affected versions Fixed in >= 2.18.0, < 2.18.2 none stated >= 2.19.0, < 2.19.3 none stated jsonRubyGems
Affected versions Fixed in from 2.19.0 to before 2.19.3 2.19.3 from 2.18.0 to before 2.18.2 2.18.2
Product versions from the CVE.org record.
Timeline
- Published
Related news
No article from the followed outlets names this vulnerability.