CVE-2022-31116

python3-ujson: UltraJSON is a fast JSON encoder and decoder written in pure C with bindings for Python 3.7+

CVE-2022-31116 is fixed in 3 products on 1 platform, first by python-ujson 1.35-2ubuntu0.1~esm1, released July 5, 2022. It is not reported as exploited. Patch Radar priority: High.

High
CVSS
7.5
Medium
Exploitation
None reported
No vendor assessment
CISA KEV
Not listed
Not in the Known Exploited Vulnerabilities catalog
EPSS
0.0255
85th percentile

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.

Where it's fixed

ProductFixed inFixReleased
Linux
python-ujson · Ubuntu 18.04.6 LTS (bionic) 1.35-2ubuntu0.1~esm1 python-ujson 1.35-2ubuntu0.1~esm1 Jul 5, 2022
python3-ujson · Ubuntu 18.04.6 LTS (bionic) 1.35-2ubuntu0.1~esm1 python3-ujson 1.35-2ubuntu0.1~esm1 Jul 5, 2022
python3-ujson · Ubuntu 22.04.1 LTS (jammy) 5.1.0-1ubuntu0.1~esm1 python3-ujson 5.1.0-1ubuntu0.1~esm1 Jul 5, 2022
ujson · Debian 12.15 (bookworm) 5.4.0-1 DEBIAN-CVE-2022-31116 Jul 5, 2022
ujson · Debian 13.5 (trixie) 5.4.0-1 DEBIAN-CVE-2022-31116 Jul 5, 2022
ujson · Debian 14 5.4.0-1 DEBIAN-CVE-2022-31116 Jul 5, 2022

Patch Radar data is free to use with attribution. Terms and how to credit it.

Product names, logos and trademarks shown on Patch Radar belong to their respective owners. They are used only to identify the software each security fix applies to and to help readers find their platform. Their use does not imply any affiliation with, or endorsement by, those owners, and Patchblox is not affiliated with any of them.