{"answers":{"affected":"It affects 3 products.","exploited":"There is no known exploitation of CVE-2021-31535 in the wild and no public exploit code.","fix":"Upgrade to a fixed version.","what":"CVE-2021-31535 is a critical code injection vulnerability in Fedoraproject Fedora, published on 27 May 2021. An attacker can exploit it over the internet without logging in, with no action from the victim."},"fix_prompt":"Check this codebase for CVE-2021-31535 and fix it if it is affected.\n\nWhat it is: CVE-2021-31535 is a critical code injection vulnerability in Fedoraproject Fedora, published on 27 May 2021. An attacker can exploit it over the internet without logging in, with no action from the victim.\nExploitation: There is no known exploitation of CVE-2021-31535 in the wild and no public exploit code.\n\nAffected product: Fedoraproject Fedora. No package-level version data is available, so check the vendor advisory linked from the reference page.\n\nTask:\n1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.\n2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.\n3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.\n4. Run the tests and summarise what changed and why.\n5. If nothing in the project is affected, say so and change nothing.\n\nReference: https://insights.sbomify.com/CVE-2021-31535/ (Markdown: https://insights.sbomify.com/CVE-2021-31535/index.md)","id":"CVE-2021-31535","markdown":"https://insights.sbomify.com/CVE-2021-31535/index.md","name":"CVE-2021-31535","record":{"aliases":["ALPINE-CVE-2021-31535","ALSA-2021:4326","DEBIAN-CVE-2021-31535","DLA-2666-1","DSA-4920-1","GHSA-3vp2-rf63-rc8p","JLSEC-2026-471","MGASA-2021-0219","OESA-2021-1235","RHSA-2021:3296","RHSA-2021:4326","RLSA-2021:4326","SUSE-SU-2021:14748-1","SUSE-SU-2021:1765-1","SUSE-SU-2021:1766-1","SUSE-SU-2021:1892-1","SUSE-SU-2021:1897-1","UBUNTU-CVE-2021-31535","USN-4966-1","USN-4966-2","openSUSE-SU-2021:0807-1","openSUSE-SU-2021:0857-1","openSUSE-SU-2021:1897-1"],"analysis":{"component_type":"library","fix_type":"upgrade","impacts":["code_execution","security_bypass"],"network_reachable":"yes","non_default_config":false,"product_category":"X11 client library","requires_auth":"none","summary":"Remote attackers can execute arbitrary code or bypass authorization by sending oversized color lookup requests to the X server via the libX11 library.","user_interaction":"not_required","vuln_class":"code_injection"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"mitre","cpe":[{"product":"fedora","vendor":"fedoraproject"},{"product":"libx11","vendor":"x.org"},{"product":"x_window_system","vendor":"x.org"}],"cvss":{"score":9.8,"severity":"critical","source":"nvd","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","version":"3.1"},"cwes":[{"id":"CWE-120","name":"Buffer Copy without Checking Size of Input"}],"description":"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.","ecosystems":["AlmaLinux:8","Red Hat:enterprise_linux:7::client","Red Hat:enterprise_linux:7::computenode","Red Hat:enterprise_linux:7::server","Red Hat:enterprise_linux:7::workstation","Red Hat:enterprise_linux:8::appstream","Rocky Linux:8","SUSE:Enterprise Storage 6","SUSE:HPE Helion OpenStack 8","SUSE:Linux Enterprise High Performance Computing 15 SP1-ESPOS","SUSE:Linux Enterprise High Performance Computing 15 SP1-LTSS","SUSE:Linux Enterprise High Performance Computing 15-ESPOS","SUSE:Linux Enterprise High Performance Computing 15-LTSS","SUSE:Linux Enterprise Micro 5.0","SUSE:Linux Enterprise Module for Basesystem 15 SP2","SUSE:Linux Enterprise Module for Basesystem 15 SP3","SUSE:Linux Enterprise Point of Sale 11 SP3","SUSE:Linux Enterprise Server 11 SP4-LTSS","SUSE:Linux Enterprise Server 12 SP2-BCL","SUSE:Linux Enterprise Server 12 SP3-BCL","SUSE:Linux Enterprise Server 12 SP3-LTSS","SUSE:Linux Enterprise Server 12 SP4-LTSS","SUSE:Linux Enterprise Server 12 SP5","SUSE:Linux Enterprise Server 15 SP1-BCL","SUSE:Linux Enterprise Server 15 SP1-LTSS","SUSE:Linux Enterprise Server 15-LTSS","SUSE:Linux Enterprise Server for SAP Applications 12 SP3","SUSE:Linux Enterprise Server for SAP Applications 12 SP4","SUSE:Linux Enterprise Server for SAP Applications 12 SP5","SUSE:Linux Enterprise Server for SAP Applications 15","SUSE:Linux Enterprise Server for SAP Applications 15 SP1","SUSE:Linux Enterprise Software Development Kit 12 SP5","SUSE:Manager Proxy 4.0","SUSE:Manager Retail Branch Server 4.0","SUSE:Manager Server 4.0","SUSE:OpenStack Cloud 8","SUSE:OpenStack Cloud 9","SUSE:OpenStack Cloud Crowbar 8","SUSE:OpenStack Cloud Crowbar 9","openSUSE:Leap 15.2","openSUSE:Leap 15.3"],"exploits":{"exploitdb":0,"first_seen":null,"github_poc":0,"max_poc_stars":null,"metasploit":0,"nuclei":0,"refs":[],"tier":"none_known"},"has_fix":true,"headline":"Code injection in n/a","id":"CVE-2021-31535","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":null,"product":"fedoraproject:fedora","products":["fedoraproject:fedora"],"type":"code_injection","year":"2021"},"n_packages":67,"n_references":19,"next":{"headline":"Cross-site scripting in n/a","id":"CVE-2021-31537"},"packages":[{"ecosystem":"AlmaLinux:8","fixed":["1.6.8-5.el8"],"introduced":["0"],"last_affected":[],"package":"libX11","purl":"pkg:rpm/almalinux/libX11","source":"ALSA-2021:4326"},{"ecosystem":"AlmaLinux:8","fixed":["1.6.8-5.el8"],"introduced":["0"],"last_affected":[],"package":"libX11-common","purl":"pkg:rpm/almalinux/libX11-common","source":"ALSA-2021:4326"},{"ecosystem":"AlmaLinux:8","fixed":["1.6.8-5.el8"],"introduced":["0"],"last_affected":[],"package":"libX11-devel","purl":"pkg:rpm/almalinux/libX11-devel","source":"ALSA-2021:4326"},{"ecosystem":"AlmaLinux:8","fixed":["1.6.8-5.el8"],"introduced":["0"],"last_affected":[],"package":"libX11-xcb","purl":"pkg:rpm/almalinux/libX11-xcb","source":"ALSA-2021:4326"},{"ecosystem":"Red Hat:enterprise_linux:7::client","fixed":["0:1.6.7-4.el7_9"],"introduced":["0"],"last_affected":[],"package":"libX11","purl":"pkg:rpm/redhat/libX11","source":"RHSA-2021:3296"},{"ecosystem":"Red Hat:enterprise_linux:7::client","fixed":["0:1.6.7-4.el7_9"],"introduced":["0"],"last_affected":[],"package":"libX11-common","purl":"pkg:rpm/redhat/libX11-common","source":"RHSA-2021:3296"},{"ecosystem":"Red Hat:enterprise_linux:7::client","fixed":["0:1.6.7-4.el7_9"],"introduced":["0"],"last_affected":[],"package":"libX11-debuginfo","purl":"pkg:rpm/redhat/libX11-debuginfo","source":"RHSA-2021:3296"},{"ecosystem":"Red Hat:enterprise_linux:7::client","fixed":["0:1.6.7-4.el7_9"],"introduced":["0"],"last_affected":[],"package":"libX11-devel","purl":"pkg:rpm/redhat/libX11-devel","source":"RHSA-2021:3296"},{"ecosystem":"Red Hat:enterprise_linux:7::computenode","fixed":["0:1.6.7-4.el7_9"],"introduced":["0"],"last_affected":[],"package":"libX11-debuginfo","purl":"pkg:rpm/redhat/libX11-debuginfo","source":"RHSA-2021:3296"},{"ecosystem":"Red Hat:enterprise_linux:7::computenode","fixed":["0:1.6.7-4.el7_9"],"introduced":["0"],"last_affected":[],"package":"libX11-devel","purl":"pkg:rpm/redhat/libX11-devel","source":"RHSA-2021:3296"},{"ecosystem":"Red Hat:enterprise_linux:7::server","fixed":["0:1.6.7-4.el7_9"],"introduced":["0"],"last_affected":[],"package":"libX11","purl":"pkg:rpm/redhat/libX11","source":"RHSA-2021:3296"},{"ecosystem":"Red Hat:enterprise_linux:7::server","fixed":["0:1.6.7-4.el7_9"],"introduced":["0"],"last_affected":[],"package":"libX11-common","purl":"pkg:rpm/redhat/libX11-common","source":"RHSA-2021:3296"},{"ecosystem":"Red Hat:enterprise_linux:7::server","fixed":["0:1.6.7-4.el7_9"],"introduced":["0"],"last_affected":[],"package":"libX11-debuginfo","purl":"pkg:rpm/redhat/libX11-debuginfo","source":"RHSA-2021:3296"},{"ecosystem":"Red Hat:enterprise_linux:7::server","fixed":["0:1.6.7-4.el7_9"],"introduced":["0"],"last_affected":[],"package":"libX11-devel","purl":"pkg:rpm/redhat/libX11-devel","source":"RHSA-2021:3296"},{"ecosystem":"Red Hat:enterprise_linux:7::workstation","fixed":["0:1.6.7-4.el7_9"],"introduced":["0"],"last_affected":[],"package":"libX11","purl":"pkg:rpm/redhat/libX11","source":"RHSA-2021:3296"},{"ecosystem":"Red Hat:enterprise_linux:7::workstation","fixed":["0:1.6.7-4.el7_9"],"introduced":["0"],"last_affected":[],"package":"libX11-common","purl":"pkg:rpm/redhat/libX11-common","source":"RHSA-2021:3296"},{"ecosystem":"Red Hat:enterprise_linux:7::workstation","fixed":["0:1.6.7-4.el7_9"],"introduced":["0"],"last_affected":[],"package":"libX11-debuginfo","purl":"pkg:rpm/redhat/libX11-debuginfo","source":"RHSA-2021:3296"},{"ecosystem":"Red Hat:enterprise_linux:7::workstation","fixed":["0:1.6.7-4.el7_9"],"introduced":["0"],"last_affected":[],"package":"libX11-devel","purl":"pkg:rpm/redhat/libX11-devel","source":"RHSA-2021:3296"},{"ecosystem":"Red Hat:enterprise_linux:8::appstream","fixed":["0:1.6.8-5.el8"],"introduced":["0"],"last_affected":[],"package":"libX11","purl":"pkg:rpm/redhat/libX11","source":"RHSA-2021:4326"},{"ecosystem":"Red Hat:enterprise_linux:8::appstream","fixed":["0:1.6.8-5.el8"],"introduced":["0"],"last_affected":[],"package":"libX11-common","purl":"pkg:rpm/redhat/libX11-common","source":"RHSA-2021:4326"},{"ecosystem":"Red Hat:enterprise_linux:8::appstream","fixed":["0:1.6.8-5.el8"],"introduced":["0"],"last_affected":[],"package":"libX11-debuginfo","purl":"pkg:rpm/redhat/libX11-debuginfo","source":"RHSA-2021:4326"},{"ecosystem":"Red Hat:enterprise_linux:8::appstream","fixed":["0:1.6.8-5.el8"],"introduced":["0"],"last_affected":[],"package":"libX11-debugsource","purl":"pkg:rpm/redhat/libX11-debugsource","source":"RHSA-2021:4326"},{"ecosystem":"Red Hat:enterprise_linux:8::appstream","fixed":["0:1.6.8-5.el8"],"introduced":["0"],"last_affected":[],"package":"libX11-devel","purl":"pkg:rpm/redhat/libX11-devel","source":"RHSA-2021:4326"},{"ecosystem":"Red Hat:enterprise_linux:8::appstream","fixed":["0:1.6.8-5.el8"],"introduced":["0"],"last_affected":[],"package":"libX11-xcb","purl":"pkg:rpm/redhat/libX11-xcb","source":"RHSA-2021:4326"},{"ecosystem":"Red Hat:enterprise_linux:8::appstream","fixed":["0:1.6.8-5.el8"],"introduced":["0"],"last_affected":[],"package":"libX11-xcb-debuginfo","purl":"pkg:rpm/redhat/libX11-xcb-debuginfo","source":"RHSA-2021:4326"},{"ecosystem":"Rocky Linux:8","fixed":["0:1.6.8-5.el8"],"introduced":["0"],"last_affected":[],"package":"libX11","purl":"pkg:rpm/rocky-linux/libX11?distro=rocky-linux-8\u0026epoch=0","source":"RLSA-2021:4326"},{"ecosystem":"SUSE:Enterprise Storage 6","fixed":["1.6.5-3.21.1"],"introduced":["0"],"last_affected":[],"package":"libX11","purl":"pkg:rpm/suse/libX11\u0026distro=SUSE%20Enterprise%20Storage%206","source":"SUSE-SU-2021:1897-1"},{"ecosystem":"SUSE:HPE Helion OpenStack 8","fixed":["1.6.2-12.21.1"],"introduced":["0"],"last_affected":[],"package":"libX11","purl":"pkg:rpm/suse/libX11\u0026distro=HPE%20Helion%20OpenStack%208","source":"SUSE-SU-2021:1892-1"},{"ecosystem":"SUSE:Linux Enterprise High Performance Computing 15 SP1-ESPOS","fixed":["1.6.5-3.21.1"],"introduced":["0"],"last_affected":[],"package":"libX11","purl":"pkg:rpm/suse/libX11\u0026distro=SUSE%20Linux%20Enterprise%20High%20Performance%20Computing%2015%20SP1-ESPOS","source":"SUSE-SU-2021:1897-1"},{"ecosystem":"SUSE:Linux Enterprise High Performance Computing 15 SP1-LTSS","fixed":["1.6.5-3.21.1"],"introduced":["0"],"last_affected":[],"package":"libX11","purl":"pkg:rpm/suse/libX11\u0026distro=SUSE%20Linux%20Enterprise%20High%20Performance%20Computing%2015%20SP1-LTSS","source":"SUSE-SU-2021:1897-1"},{"ecosystem":"SUSE:Linux Enterprise High Performance Computing 15-ESPOS","fixed":["1.6.5-3.21.1"],"introduced":["0"],"last_affected":[],"package":"libX11","purl":"pkg:rpm/suse/libX11\u0026distro=SUSE%20Linux%20Enterprise%20High%20Performance%20Computing%2015-ESPOS","source":"SUSE-SU-2021:1897-1"},{"ecosystem":"SUSE:Linux Enterprise High Performance Computing 15-LTSS","fixed":["1.6.5-3.21.1"],"introduced":["0"],"last_affected":[],"package":"libX11","purl":"pkg:rpm/suse/libX11\u0026distro=SUSE%20Linux%20Enterprise%20High%20Performance%20Computing%2015-LTSS","source":"SUSE-SU-2021:1897-1"},{"ecosystem":"SUSE:Linux Enterprise Micro 5.0","fixed":["1.6.5-3.18.1"],"introduced":["0"],"last_affected":[],"package":"libX11","purl":"pkg:rpm/suse/libX11\u0026distro=SUSE%20Linux%20Enterprise%20Micro%205.0","source":"SUSE-SU-2021:1765-1"},{"ecosystem":"SUSE:Linux Enterprise Micro 5.0","fixed":["1.6.5-3.21.1"],"introduced":["0"],"last_affected":[],"package":"libX11","purl":"pkg:rpm/suse/libX11\u0026distro=SUSE%20Linux%20Enterprise%20Micro%205.0","source":"SUSE-SU-2021:1897-1"},{"ecosystem":"SUSE:Linux Enterprise Module for Basesystem 15 SP2","fixed":["1.6.5-3.18.1"],"introduced":["0"],"last_affected":[],"package":"libX11","purl":"pkg:rpm/suse/libX11\u0026distro=SUSE%20Linux%20Enterprise%20Module%20for%20Basesystem%2015%20SP2","source":"SUSE-SU-2021:1765-1"},{"ecosystem":"SUSE:Linux Enterprise Module for Basesystem 15 SP2","fixed":["1.6.5-3.21.1"],"introduced":["0"],"last_affected":[],"package":"libX11","purl":"pkg:rpm/suse/libX11\u0026distro=SUSE%20Linux%20Enterprise%20Module%20for%20Basesystem%2015%20SP2","source":"SUSE-SU-2021:1897-1"},{"ecosystem":"SUSE:Linux Enterprise Module for Basesystem 15 SP3","fixed":["1.6.5-3.18.1"],"introduced":["0"],"last_affected":[],"package":"libX11","purl":"pkg:rpm/suse/libX11\u0026distro=SUSE%20Linux%20Enterprise%20Module%20for%20Basesystem%2015%20SP3","source":"SUSE-SU-2021:1765-1"},{"ecosystem":"SUSE:Linux Enterprise Module for Basesystem 15 SP3","fixed":["1.6.5-3.21.1"],"introduced":["0"],"last_affected":[],"package":"libX11","purl":"pkg:rpm/suse/libX11\u0026distro=SUSE%20Linux%20Enterprise%20Module%20for%20Basesystem%2015%20SP3","source":"SUSE-SU-2021:1897-1"},{"ecosystem":"SUSE:Linux Enterprise Point of Sale 11 SP3","fixed":["7.4-5.11.72.27.1"],"introduced":["0"],"last_affected":[],"package":"xorg-x11-libX11","purl":"pkg:rpm/suse/xorg-x11-libX11\u0026distro=SUSE%20Linux%20Enterprise%20Point%20of%20Sale%2011%20SP3","source":"SUSE-SU-2021:14748-1"},{"ecosystem":"SUSE:Linux Enterprise Server 11 SP4-LTSS","fixed":["7.4-5.11.72.27.1"],"introduced":["0"],"last_affected":[],"package":"xorg-x11-libX11","purl":"pkg:rpm/suse/xorg-x11-libX11\u0026distro=SUSE%20Linux%20Enterprise%20Server%2011%20SP4-LTSS","source":"SUSE-SU-2021:14748-1"}],"prev":{"headline":"Security feature bypass in n/a","id":"CVE-2021-31532"},"products":["n/a"],"published":"2021-05-27","related":[{"cvss_score":9.8,"headline":"PHP-CGI OS Command Injection","id":"CVE-2024-4577","kev_date_added":"2024-06-12","published":"2024-06-09"},{"cvss_score":9.8,"headline":"Grafana Authentication Bypass","id":"CVE-2021-39226","kev_date_added":"2022-08-25","published":"2021-10-05"},{"cvss_score":9.8,"headline":"VMware ESXi and Horizon DaaS OpenSLP Heap-Based Buffer Overflow","id":"CVE-2019-5544","kev_date_added":"2021-11-03","published":"2019-12-06"},{"cvss_score":9.6,"headline":"Google Chromium V8 Type Confusion","id":"CVE-2024-4947","kev_date_added":"2024-05-20","published":"2024-05-15"},{"cvss_score":9.6,"headline":"Google Chromium Visuals Use-After-Free","id":"CVE-2024-4671","kev_date_added":"2024-05-13","published":"2024-05-09"},{"cvss_score":9.6,"headline":"Google Chromium Mojo Insufficient Data Validation","id":"CVE-2022-3075","kev_date_added":"2022-09-08","published":"2022-09-26"},{"cvss_score":9.6,"headline":"Google Chromium Indexed DB API Use-After-Free","id":"CVE-2021-30633","kev_date_added":"2021-11-03","published":"2021-10-08"}],"sources":[{"class":"attribution","licence":"MIT","name":"AlmaLinux","prefix":"ALSA"},{"class":"attribution","licence":"CVE Terms of Use (MITRE)","name":"CVE List","prefix":"CVE"},{"class":"attribution","licence":"CC BY 4.0","name":"Red Hat","prefix":"RHSA"},{"class":"attribution","licence":"BSD","name":"Rocky Linux","prefix":"RLSA"},{"class":"attribution","licence":"CC BY 4.0","name":"SUSE","prefix":"SUSE"},{"class":"attribution","licence":"US public information, NVD API terms","name":"NVD"},{"class":"attribution","licence":"CWE Terms of Use","name":"CWE (MITRE)"},{"class":"attribution","licence":"FIRST CVSS licence","name":"CVSS (FIRST)"}],"ssvc":{"automatable":null,"exploitation":null,"technical_impact":null},"state":"PUBLISHED","updated":"2024-08-03","vendors":["n/a"]},"summary":"Remote attackers can execute arbitrary code or bypass authorization by sending oversized color lookup requests to the X server via the libX11 library.","url":"https://insights.sbomify.com/CVE-2021-31535/"}