CVE Watchtower

CVE-2026-9323urwid

NVD

Vulnerability Summary

The urwid web display backend (urwid/display/web.py) generates web session identifiers (urwid_id) in Screen.start() by concatenating two random.randrange(10**9) calls that use Python's Mersenne Twister PRNG, which is not cryptographically secure. Each call consumes approximately 30 bits of PRNG state, and the Mersenne Twister internal state is approximately 19,937 bits, so an attacker who observes approximately 334 session IDs (for example via the X-Urwid-ID HTTP response header) can fully reconstruct the internal state and predict all past and future session IDs (Path B). The same identifier is also used as the filename of a FIFO created in the world-listable /tmp directory (for example /tmp/urwid375487765176907690.in), so any local user on the host can list /tmp to enumerate active session tokens directly (Path A). With a valid session ID, an attacker can read the victim's terminal screen via the polling endpoint, inject keystrokes into the victim's session (yielding OS-level code execution with the session owner's privileges if the session runs a shell), and inject exit sequences or flood the FIFO to terminate or crash the session. A prior Bandit S311 warning on this usage was suppressed with # noqa: S311 rather than fixed
Severity Level
CRITICAL(9.2)
Published Date
Jul 18, 2026
Last Modified
Nov 20, 2026
Exploitation Status
No confirmed exploitation yet
EPSS Score (30-Day)
0.72%Probability
Root Weakness (CWE)
See the MITRE CWE entry for the full definition of this weakness.
CVSS v4.0 Base Metrics — Score 9.2 (CRITICAL)
CVSS:4.0/AV:N/AC:H/AT:P/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
Attack VectorNetwork
Attack ComplexityHigh
Attack RequirementsPresent
Privileges RequiredNone
User InteractionNone
Confidentiality (Vulnerable System)High
Integrity (Vulnerable System)High
Availability (Vulnerable System)High
Confidentiality (Subsequent System)None
Integrity (Subsequent System)None
Availability (Subsequent System)None
Show CVSS v3.x metrics (score 8.1)
CVSS v3.1 Base Metrics — Score 8.1 (HIGH)
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
Attack VectorNetwork
Attack ComplexityHigh
Privileges RequiredNone
User InteractionNone
ScopeUnchanged
ConfidentialityHigh
IntegrityHigh
AvailabilityHigh

Affected & Patched Versions

Affected Versions
  • urwid < 5.1.0
Patched Versions
  • urwid 5.1.0

What to do

Plan remediation soon. No exploitation is confirmed yet, but the severity is critical.

  1. Check whether you run urwid and which version.
  2. Update to a patched version listed above, then confirm the new version.

Timeline

  • Jul 18, 2026Published
  • Nov 20, 2026Record last modified

Score, severity and exploitation changes are tracked from the day Watchtower started logging them.

Get notified about new urwid CVEsYou are reading CVE-2026-9323. Get an email when KEV listings, exploits or new CVEs match your stack.
Set up CVE alerts

More urwid CVEs

Data last checked: Nov 20, 2026 15:32 UTC