Skip to main content
← All vulnerabilities
CVE-2026-54899GHSA-2CW7-V8FF-P88R

Oj: Use-After-Free in Oj::Parser Symbol Key Cache Toggle

Published
Last modified
published
Not listed in CISA KEV
Fix
Fixed in 3.17.2
None on Exploit-DB, Metasploit or GitHub
  • Exploitation: poc
  • Automatable: no
  • Technical impact: partial

Summary

Oj (Optimized JSON) is a JSON parser and Object marshaller packaged as a Ruby gem. Prior to version 3.17.2, disabling symbol_keys on a reused Oj::Parser instance triggers a heap use-after-free. When symbol_keys is toggled from true to false, opt_symbol_keys_set frees the internal key cache (cache_free) but does not clear the pointer. The next parse call reads from the freed cache via cache_intern, producing a use-after-free. This issue has been fixed in version 3.17.2.

Timeline

  1. CVE published
  2. CISA SSVC assessment

    Exploitation: poc · Automatable: no · Technical impact: partial

  3. Record last updated

Affected versions

  • ohler55 oj

    fixed in 3.17.2

  • ojRubyGems

    fixed in 3.17.2

References 1

GitHub · ohler55/oj