CVE-2026-54903: CWE-190: Integer Overflow or Wraparound in ohler55 oj
Oj (Optimized JSON) is a JSON parser and Object marshaller packaged as a Ruby gem. In versions prior to 3.17.2, Oj.load is vulnerable to heap corruption when parsing a JSON string longer than 2 GB. An integer overflow in buf_append_string (buf.h:61) converts the string length to a large negative size_t, causing memcpy to copy an astronomically large amount of data out of bounds. This crashes the process and can corrupt adjacent heap memory. The issue has been fixed in version 3.17.2.
AI Analysis
Technical Summary
CVE-2026-54903 is an integer overflow vulnerability (CWE-190) in the Oj Ruby gem before version 3.17.2. The vulnerability occurs in the buf_append_string function (buf.h:61) when parsing JSON strings exceeding 2 GB in length. The string length is converted to a large negative size_t value, causing memcpy to copy an astronomically large amount of data out of bounds. This results in heap corruption and process crashes. The vulnerability has a CVSS 4.0 base score of 6.3 (medium severity) and requires no privileges or user interaction to exploit, but an attacker must supply a specially crafted large JSON string. The issue is resolved in version 3.17.2.
Potential Impact
Exploitation of this vulnerability can cause the Oj parser process to crash and corrupt adjacent heap memory. This may lead to denial of service or potentially unpredictable behavior due to memory corruption. There is no indication of remote code execution or data disclosure from the provided data.
Mitigation Recommendations
Upgrade Oj to version 3.17.2 or later, where this integer overflow and heap corruption issue has been fixed. Patch status is confirmed by the vendor's versioning information. No other mitigations are indicated.
CVE-2026-54903: CWE-190: Integer Overflow or Wraparound in ohler55 oj
Description
Oj (Optimized JSON) is a JSON parser and Object marshaller packaged as a Ruby gem. In versions prior to 3.17.2, Oj.load is vulnerable to heap corruption when parsing a JSON string longer than 2 GB. An integer overflow in buf_append_string (buf.h:61) converts the string length to a large negative size_t, causing memcpy to copy an astronomically large amount of data out of bounds. This crashes the process and can corrupt adjacent heap memory. The issue has been fixed in version 3.17.2.
CVSS v4.0
Score 6.3medium
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
CVE-2026-54903 is an integer overflow vulnerability (CWE-190) in the Oj Ruby gem before version 3.17.2. The vulnerability occurs in the buf_append_string function (buf.h:61) when parsing JSON strings exceeding 2 GB in length. The string length is converted to a large negative size_t value, causing memcpy to copy an astronomically large amount of data out of bounds. This results in heap corruption and process crashes. The vulnerability has a CVSS 4.0 base score of 6.3 (medium severity) and requires no privileges or user interaction to exploit, but an attacker must supply a specially crafted large JSON string. The issue is resolved in version 3.17.2.
Potential Impact
Exploitation of this vulnerability can cause the Oj parser process to crash and corrupt adjacent heap memory. This may lead to denial of service or potentially unpredictable behavior due to memory corruption. There is no indication of remote code execution or data disclosure from the provided data.
Mitigation Recommendations
Upgrade Oj to version 3.17.2 or later, where this integer overflow and heap corruption issue has been fixed. Patch status is confirmed by the vendor's versioning information. No other mitigations are indicated.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2026-06-16T13:49:33.555Z
- Cvss Version
- 4.0
- State
- PUBLISHED
- Remediation Level
- null
Threat ID: 6a445a0927e9c7971999d8a3
Added to database: 07/01/2026, 00:06:33 UTC
Last enriched: 07/08/2026, 12:53:42 UTC
Last updated: 08/11/2026, 16:03:15 UTC
Views: 76
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
External Links
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.