Skip to content
EXYS
Back to the CVEs

CVE-2021-3156

7.8, high Known exploited

Sudo Heap-Based Buffer Overflow Vulnerability

CVSS
7.8, high high CVSS v3.1
EPSS, next 30 days
100% higher than 99.9% of scored CVEs
Exploitation
Confirmed in the wild
Published
26 Jan 20215 years ago

Known exploited

CISA added this to the Known Exploited Vulnerabilities Catalog on 6 Apr 2022. US federal agencies had to remediate by 27 Apr 2022, a deadline that has passed.

Required action. Apply updates per vendor instructions.

Description

Sudo before 1.9.5p2 contains an off-by-one error that can result in a heap-based buffer overflow, which allows privilege escalation to root via "sudoedit -s" and a command-line argument that ends with a single backslash character.

Details

Vendor
Sudo and 7 more
Product
Sudo
Weakness
CWE-193 (opens in a new tab)
Status
Analyzed
Updated
17 Jun 2026
Assigner
cve@mitre.org

CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

References 35

The kind is read from NVD's tags where present and from the shape of the URL otherwise, so treat it as a hint.

Other Sudo CVEs

Every Sudo CVE we hold

Same vendor in what we hold, not a known link between the flaws.

  • CVE-2025-32463 Sudo Inclusion of Functionality from Untrusted Control Sphere Vulnerability KEV EPSS 55% 7.8, high

Beyond this page

Is CVE-2021-3156 in your network?

This page tells you how dangerous CVE-2021-3156 is out there. Whether it sits on one of your devices, only a scan of your own network can tell. That is what our systems do, every day, for the companies we protect.

CVE-2021-3156 is in the CISA catalogue of exploited vulnerabilities: attackers are already exploiting it.

  • EXYS7600 OCELOT

    Find it before attackers do

    Ocelot scans your network on a schedule and reports every vulnerability it finds by its CVE identifier, with its CVSS score and how many of your hosts are affected. A finding like CVE-2021-3156 comes with the devices to patch.

    Learn more about EXYS7600 OCELOT
  • EXYS7950 KONDRA

    Detect it if it's exploited

    Until the patch is applied, Kondra monitors your network, events and endpoints in real time. It keeps an inventory of the software installed on every endpoint, and its anomaly detection rules flag what an attacker does once inside.

    Learn more about EXYS7950 KONDRA
Check your exposure

Assembled from the NVD 2.0 API, the CISA Known Exploited Vulnerabilities Catalog and FIRST EPSS. Scores are as of our last collection on 18 Oct 2026, not the live upstream state.