Vulnerability Information
Although we use advanced large model technology, its output may still contain inaccurate or outdated information.Shenlong tries to ensure data accuracy, but please verify and judge based on the actual situation.
Vulnerability Title
Insecure PRNG and Information Exposure in urwid Web Display Backend
Vulnerability Description
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
CVSS Information
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
Vulnerability Type
使用具有密码学弱点缺陷的PRNG
Vulnerability Title
urwid 加密问题漏洞
Vulnerability Description
urwid Urwid是urwid团队的一款基于控制台的UI工具库,用于创建文本用户界面。 urwid 24acd12及之前版本存在加密问题漏洞,该漏洞源于Web显示后端生成会话标识符时使用非加密安全的Mersenne Twister PRNG,导致攻击者通过观察约334个会话ID可重构内部状态并预测所有历史及未来会话ID,且会话标识符也用作/tmp目录中FIFO文件名,使本地用户可直接枚举活跃会话令牌,进而读取受害者终端屏幕、注入按键实现OS级代码执行,或注入退出序列淹没FIFO导致会话终止或崩溃。
CVSS Information
N/A
Vulnerability Type
N/A