CVE-2022-31116
CVE-2022-31116 · Incorrect handling of invalid surrogate pair characters in ujson
This page contains facts from public vulnerability sources. Check the original advisory before updating.
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.
CVSS 7.5 · High · EPSS 2.5% · Fix available
- Published
- Updated
Affected products and versions
ultrajson
- Versions
- < 5.4.0: Affected
No fix published
ujson Debian:12
- Affected ranges
- ECOSYSTEM: < 5.4.0-1
Update to 5.4.0-1
ujson Debian:13
- Affected ranges
- ECOSYSTEM: < 5.4.0-1
Update to 5.4.0-1
ujson Debian:14
- Affected ranges
- ECOSYSTEM: < 5.4.0-1
Update to 5.4.0-1
ujson PyPI
- Versions
- 1.15
- 1.18
- 1.19
- 1.21
- 1.22
- 1.23
- 1.30
- 1.33
- 1.34
- 1.35
- 1.4
- 1.6
- 1.8
- 1.9
- 2.0.0
- 2.0.1
- 2.0.2
- 2.0.3
- 3.0.0
- 3.1.0
- 3.2.0
- 4.0.0
- 4.0.1
- 4.0.2
- 4.1.0
- 4.2.0
- 4.3.0
- 5.0.0
- 5.1.0
- 5.2.0
- 5.3.0
- Affected ranges
- ECOSYSTEM: < 5.4.0
Update to 5.4.0
pandas Ubuntu:14.04:LTS
- Versions
- 0.12.0-2ubuntu1
- 0.13.1-2ubuntu1
- 0.13.1-2ubuntu2
- Affected ranges
- ECOSYSTEM: (−∞, +∞)
No fix published
ujson Ubuntu:Pro:16.04:LTS
- Versions
- 1.33-1
- 1.33-1build1
- Affected ranges
- ECOSYSTEM: < 1.33-1ubuntu0.1~esm2
Update to 1.33-1ubuntu0.1~esm2
collada2gltf Ubuntu:16.04:LTS
- Versions
- 20140924-3
- Affected ranges
- ECOSYSTEM: (−∞, +∞)
No fix published
pandas Ubuntu:16.04:LTS
- Versions
- 0.15.0-2
- 0.15.0-2ubuntu1
- 0.15.0-2ubuntu2
- 0.17.1-3ubuntu2
- Affected ranges
- ECOSYSTEM: (−∞, +∞)
No fix published
collada2gltf Ubuntu:18.04:LTS
- Versions
- 20140924-4
- Affected ranges
- ECOSYSTEM: (−∞, +∞)
No fix published
pandas Ubuntu:18.04:LTS
- Versions
- 0.19.2-5.1ubuntu4
- 0.22.0-2ubuntu1
- 0.22.0-3
- 0.22.0-4
- 0.22.0-4ubuntu1
- Affected ranges
- ECOSYSTEM: (−∞, +∞)
No fix published
ujson Ubuntu:Pro:18.04:LTS
- Versions
- 1.35-1build2
- 1.35-2
- Affected ranges
- ECOSYSTEM: < 1.35-2ubuntu0.1~esm1
Update to 1.35-2ubuntu0.1~esm1
pandas Ubuntu:20.04:LTS
- Versions
- 0.23.3+dfsg-4ubuntu1
- 0.23.3+dfsg-4ubuntu5
- 0.23.3+dfsg-4ubuntu6
- 0.25.3+dfsg-4
- 0.25.3+dfsg-4build1
- 0.25.3+dfsg-7
- Affected ranges
- ECOSYSTEM: (−∞, +∞)
No fix published
collada2gltf Ubuntu:22.04:LTS
- Versions
- 20140924-7build1
- 20140924-8
- Affected ranges
- ECOSYSTEM: (−∞, +∞)
No fix published
pandas Ubuntu:22.04:LTS
- Versions
- 1.1.5+dfsg-2
- 1.1.5+dfsg-2ubuntu1
- 1.3.5+dfsg-2
- 1.3.5+dfsg-2ubuntu1
- 1.3.5+dfsg-3
- Affected ranges
- ECOSYSTEM: (−∞, +∞)
No fix published
ujson Ubuntu:Pro:22.04:LTS
- Versions
- 4.0.2-1
- 4.0.2-1build1
- 4.2.0-1
- 5.1.0-1
- 5.1.0-1build1
- Affected ranges
- ECOSYSTEM: < 5.1.0-1ubuntu0.1~esm1
Update to 5.1.0-1ubuntu0.1~esm1
pandas Ubuntu:24.04:LTS
- Versions
- 1.5.3+dfsg-6
- 1.5.3+dfsg-6ubuntu1
- 1.5.3+dfsg-7ubuntu1
- 1.5.3+dfsg-10
- 2.1.4+dfsg-4ubuntu2
- 2.1.4+dfsg-7
- Affected ranges
- ECOSYSTEM: (−∞, +∞)
No fix published
pandas Ubuntu:25.10
- Versions
- 2.2.3+dfsg-8build1
- 2.2.3+dfsg-9
- Affected ranges
- ECOSYSTEM: (−∞, +∞)
No fix published
pandas Ubuntu:26.10
- Versions
- 2.3.3+dfsg-3ubuntu1
- 2.3.3+dfsg-3ubuntu3
- Affected ranges
- ECOSYSTEM: (−∞, +∞)
No fix published
pandas Ubuntu:26.04:LTS
- Versions
- 2.2.3+dfsg-9
- 2.3.3+dfsg-1ubuntu1
- 2.3.3+dfsg-3
- 2.3.3+dfsg-3ubuntu1
- Affected ranges
- ECOSYSTEM: (−∞, +∞)
No fix published
Original sources
- https://github.com/ultrajson/ultrajson/security/advisories/GHSA-wpqr-jcpx-745r
- https://github.com/ultrajson/ultrajson/commit/67ec07183342589d602e0fcf7bb1ff3e19272687
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/OPPU5FZP3LCTXYORFH7NHUMYA5X66IA7/
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/NAU5N4A7EUK2AMUCOLYDD5ARXAJYZBD2/
- https://nvd.nist.gov/vuln/detail/CVE-2022-31116