CVE-2021-45958
Python vulnerability analysis and mitigation

Overview

UltraJSON (aka ujson) through version 5.1.0 contains a stack-based buffer overflow vulnerability in the Buffer_AppendIndentUnchecked function when called from encode. The vulnerability was discovered in late 2021 and assigned CVE-2021-45958. The issue affects all versions of ujson up to and including 5.1.0 (NVD, OSS-Fuzz).

Technical details

The vulnerability occurs in the Buffer_AppendIndentUnchecked function when handling indentation during JSON encoding. The buffer overflow can be triggered by using a large amount of indentation in the JSON encoding process. The issue has been assigned a CVSS v3.1 Base Score of 5.5 (Medium) with vector CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H (NVD).

Impact

When exploited, this vulnerability can lead to a denial of service condition through program crashes. The buffer overflow could potentially corrupt memory, though no confidentiality or integrity impacts have been reported (USN-6629-1).

Mitigation and workarounds

The vulnerability was fixed in version 5.2.0 of ujson. Users are recommended to upgrade to this version or later. The fix includes proper buffer overflow checks and improved memory handling (Fedora Update).

Additional resources


SourceThis report was generated using AI

Related Python vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2025-66471HIGH8.9
  • PythonPython
  • py3-urllib3
NoYesDec 05, 2025
CVE-2025-66418HIGH8.9
  • PythonPython
  • python-urllib3
NoYesDec 05, 2025
CVE-2025-65958HIGH8.5
  • PythonPython
  • cpe:2.3:a:openwebui:open_webui
NoYesDec 04, 2025
CVE-2025-56427HIGH7.5
  • PythonPython
  • composio
NoNoDec 04, 2025
CVE-2025-63681MEDIUM4.3
  • PythonPython
  • open-webui
NoNoDec 04, 2025

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management