VDB
Sign up
MEDIUM6.5

PYSEC-2026-2294

Quick fix

PYSEC-2026-2294 — ujson: upgrade to the fixed version with the command below.

pip install --upgrade 'ujson>=5.13.0'

Details

UltraJSON is a fast JSON encoder and decoder written in pure C with bindings for Python 3.7+. Prior to 5.13.0, ujson.dumps() (or ujson.dump() or ujson.encode()) have a reject_bytes=False option. When set, they may accept malformed or truncated UTF-8 byte sequences, silently rewriting them into different Unicode characters instead of rejecting them. This leads to input validation bypass and data integrity issues. This vulnerability is fixed in 5.13.0.

Are you affected?

Enter the version of the package you're using.

Affected packages

PyPI/ujson
Introduced in: 0Fixed in: 5.13.0
Fixpip install --upgrade 'ujson>=5.13.0'

References