CVE-2026-103022

Urwid: handle_short_request() crashes on non-ASCII POST body (UnicodeEncodeError DoS)

Published Nov 6, 2026 CVSS 3.1 · 5.3 Medium EPSS < 1% KEV · Not listed
Description
Urwid is a console user interface library for Python. Prior to 4.0.7, handle_short_request() in urwid/display/web.py performs unguarded character encoding on POST input and unguarded UTF-8 decoding on polling update socket output. A remote attacker who obtains a valid X-Urwid-ID session token can submit non-ASCII POST data that raises UnicodeEncodeError, while non-UTF-8 polling output raises UnicodeDecodeError, causing the CGI handler to return an error and terminate request processing. The POST exception path also leaves an opened file descriptor unclosed for the CGI process lifetime, so repeated requests can cause denial of service for the web display interface. This issue is fixed in version 4.0.7.

Remediation

No solution or workaround provided in the CVE record

Tracking

Sign in to view the affected projects.

Advisories

Source ID Title
Github GHSA Github GHSA GHSA-cp25-j9x5-p5xm Urwid: handle_short_request() crashes on non-ASCII POST body (UnicodeEncodeError DoS)
History
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'yes', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
First Time appeared Urwid
Urwid urwid
Vendors & Products Urwid
Urwid urwid
Type Values Removed Values Added
Description Urwid is a console user interface library for Python. Prior to 4.0.7, handle_short_request() in urwid/display/web.py performs unguarded character encoding on POST input and unguarded UTF-8 decoding on polling update socket output. A remote attacker who obtains a valid X-Urwid-ID session token can submit non-ASCII POST data that raises UnicodeEncodeError, while non-UTF-8 polling output raises UnicodeDecodeError, causing the CGI handler to return an error and terminate request processing. The POST exception path also leaves an opened file descriptor unclosed for the CGI process lifetime, so repeated requests can cause denial of service for the web display interface. This issue is fixed in version 4.0.7.
Title Urwid: handle_short_request() crashes on non-ASCII POST body (UnicodeEncodeError DoS)
Weaknesses CWE-116
CWE-248
CWE-775
References
Metrics cvssV3_1

{'score': 5.3, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L'}

Weaknesses

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Nov 11, 2026, 3:39 AM
Reserved
Sep 29, 2026, 9:13 PM
Status
Deferred
Published
Nov 6, 2026, 10:17 PM
Modified
Nov 12, 2026, 10:11 PM