Vulnerability in Ultrajson
CVE-2022-31116
UltraJSON is a fast JSON encoder and decoder written in pure C with bindings for Python 3.7+. Affected versions were found to improperly decode certain characters. JSON strings that contain escaped surrogate characters not part of a proper surrogate pair were decoded incorrectly. Besides corrupting strings, this allowed for potential key confusion and value overwriting in dictionaries. All users parsing JSON from untrusted sources are vulnerable. From version 5.4.0, UltraJSON decodes lone surrogates in the same way as the standard library's `json` module does, preserving them in the parsed output. Users are advised to upgrade. There are no known workarounds for this issue.
Published · last modified .
CVSS v3 metric
CVSS v3 base score 7.5 (High). Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H.
EPSS exploit prediction
EPSS 0.025, 85.3th percentile (last changed ); unchanged over 30 days. About EPSS.
Affected products
- Ultrajson — versions < 5.4.0
- Ultrajson Project
- Fedoraproject Fedora — versions 35, 36
Weakness classification (CWE)
Public exploits and proof-of-concept code
Also mentioned in 1 other repository (ARPSyndicate/cvemon). These reference the CVE in a list, notes or a scanner and are not exploit code for it.
References
- github.com/ultrajson/ultrajson/security/advisories/GHSA-wpqr-jcpx-745r (Exploit, Third Party Advisory)
- github.com/ultrajson/ultrajson/commit/67ec07183342589d602e0fcf7bb1ff3e19272687 (Patch, Third Party Advisory)
- FEDORA-2022-1b2b8d5177 (vendor-advisory)
- FEDORA-2022-33e816bc37 (vendor-advisory)