VDB

CVE-2021-3156

CVE-2021-3156 PUBLISHED CVSS 7.8 HIGH

Reported by mitre · Published January 26, 2021

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.

Fixed versions

Upgrade to a fixed version or later. Language registries are listed first, then Linux distributions, then vendor products.

PackageEcosystemFixed in
sudoArch Linux1.9.5.p2-1
sudoAmazon Linux1.8.23-4.amzn2.2.1
sudoAlpine1.9.5p2-r0, 1.9.5_p2-r0, 1.8.31-r1
micros_workstation_6_firmwareoracle655
sudoUbuntu:16.04:LTS1.8.16-0ubuntu1.10
privilege_management_for_unix\/linuxbeyondtrust10.3.2-10
privilege_management_for_macbeyondtrust21.1.1
tekelec_platform_distributionoracle7.7.1
communications_performance_intelligence_centeroracle10.4.0.3.1, 10.3.0.2.1
sudoUbuntu:Pro:14.04:LTS1.8.9p5-1ubuntu1.5+esm6

Risk scores

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

Affected products

VendorProductVersions
n/an/an/a
archsudo0
amazon:2sudo0
alpinesudo0, 0, 0
n/an/a*
amazon:2sudo-devel0

Timeline

  • Jan 26, 2021 CVE Published
  • Jan 27, 2021 PoC Published (12 in total, the first dated here)
  • Jan 28, 2021 VulnCheck XDB Entry (82 in total, the first dated here)
  • Apr 14, 2021 EPSS Score (30 in total, the first dated here)
  • Apr 6, 2022 CISA KEV Added
  • Apr 6, 2022 VulnCheck KEV Exploitation (10 in total, the first dated here)
  • Mar 7, 2026 Distribution Patch (17 in total, the first dated here)
  • Mar 7, 2026 Security Advisory (27 in total, the first dated here)
  • Aug 2, 2026 Coalition ESS Score

Query this with the API

The same record, from the CLI:

vulnetix vdb vuln CVE-2021-3156
vulnetix vdb fixes CVE-2021-3156

Or with curl, using the org id and key from your account page:

curl -s -H "Authorization: ApiKey ${VULNETIX_ORG_ID}:${VULNETIX_API_KEY}" \
  "https://api.vdb.vulnetix.com/v2/vuln/CVE-2021-3156/fixes/registry"

The Community plan is free and allows 50 queries a day. Get a free API key · API quickstart

Look up in the Resolve Platform →
$ Lookup Community · 50/day Open Lookup ›