Buffer overflow in X.org Libx11
CVE-2021-31535
LookupCol.c in X.Org X through X11R7.7 and libX11 before 1.7.1 might allow remote attackers to execute arbitrary code. The libX11 XLookupColor request (intended for server-side color lookup) contains a flaw allowing a client to send color-name requests with a name longer than the maximum size allowed by the protocol (and also longer than the maximum packet size for normal-sized packets). The user-controlled data exceeding the maximum size is then interpreted by the server as additional X protocol requests and executed, e.g., to disable X server authorization completely. For example, if the victim encounters malicious terminal control sequences for color codes, then the attacker may be able to take full control of the running graphical session.
Vulnerability class: Buffer Overflow
Published · last modified .
CVSS v3 metric
CVSS v3 base score 9.8 (Critical). Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H.
EPSS exploit prediction
EPSS: 0.106 (95.8th percentile), scored .
Moderate probability of exploitation in the next 30 days — watch for active exploitation reports. 96th percentile — 95.8% of CVEs in the catalogue have a lower EPSS than this one. How to read EPSS.
EPSS over last 30 days · oldest: 0.106 · newest: 0.106 · change: 0.000
Affected products
- X.org Libx11
- X.org X Window System
- Fedoraproject Fedora — versions 33
Weakness classification (CWE)
Public proof-of-concept exploits
References
- unparalleled.eu/publications/2021/advisory-unpar-2021-1.txt (Exploit, Third Party Advisory)
- lists.freedesktop.org/archives/xorg/ (Third Party Advisory)
- www.openwall.com/lists/oss-security/2021/05/18/2 (mailing-list, Mailing List, Third Party Advisory)
- seclists.org/fulldisclosure/2021/May/52 (mailing-list, Mailing List, Third Party Advisory)
- packetstormsecurity.com/files/162737/libX11-Insufficient-Length-Check-Injection… (Exploit, VDB Entry, Third Party Advisory)
- lists.debian.org/debian-lts-announce/2021/05/msg00021.html (mailing-list, Third Party Advisory)
- www.debian.org/security/2021/dsa-4920 (vendor-advisory, Third Party Advisory)
- security.gentoo.org/glsa/202105-16 (vendor-advisory, Third Party Advisory)
- www.openwall.com/lists/oss-security/2021/05/18/3 (Mailing List, Third Party Advisory)
- www.openwall.com/lists/oss-security/2021/05/18/2 (Mailing List, Third Party Advisory)
Frequently asked questions
- What is CVE-2021-31535?
- CVE-2021-31535 is a critical-severity vulnerability in X.org Libx11, classified under Buffer Copy without Checking Size of Input (Classic Buffer Overflow). CVSS score: 9.8/10. Published 2021-05-27.
- How severe is CVE-2021-31535?
- Critical severity. CVSS v3 base score is 9.8 out of 10.
- Is CVE-2021-31535 known to be exploited?
- 19 public proof-of-concept repositories are indexed. Not currently listed in the CISA KEV catalog.