CVE-2020-7247Opensmtpd OS Command Injection
smtp_mailaddr in smtp_session.c in OpenSMTPD 6.6, as used in OpenBSD 6.6 and other products, allows remote attackers to execute arbitrary commands as root via a crafted SMTP session, as demonstrated by shell metacharacters in a MAIL FROM field.
Published Jan 29, 2020 · Updated Nov 29, 2026 · Also known as ALPINE-CVE-2020-7247, CLEANSTART-2024-GM77139, DEBIAN-CVE-2020-7247, DSA-4611-1, UBUNTU-CVE-2020-7247, USN-4268-1, USN-4875-1
Key Facts
Patch immediately- CVE-2020-7247 is a critical-severity vulnerability (CVSS 9.8 v3.1) affecting Opensmtpd (Openbsd), Ubuntu Linux (Canonical), Debian Linux and 1 more product.
- It is exploited in the wild, listed in CISA KEV, Industry KEV feed, CIRCL KEV, ENISA EUVD since Mar 25, 2022. A public exploit is reported by tracking sources, but no code link is listed yet.
- EPSS estimates a 99% probability of exploitation in the next 30 days.
- Fixed versions are available, including Opensmtpd 5.4.1p1-1ubuntu0.1~esm1, Opensmtpd 5.7.3p2-1ubuntu0.1~esm1, Opensmtpd 5.7.3p2-1ubuntu0.1~esm2.
- Brandefense priority: patch immediately, because it is listed as exploited in the wild.
Scores
CVSS v3.1
9.8
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
EPSS (30-day exploit likelihood)
99%
Higher than 99.9% of all scored CVEs
Exploit maturity
Exploited (KEV)
ATLAS score
86/100
Publication score, see How it works
Exploitation Verdict
KEV listed
Mar 25, 2022
786 days after publication
Federal due date
Apr 15, 2022
Overdue
Ransomware use
Not reported
Attributed actors
None named
Exploit & Defence Guidance
Exploit maturity
Exploited (KEV)
Public exploit code
8
Proof-of-concept links
In-the-wild evidence
4
Reports of active use
Required action (CISA): Apply updates per vendor instructions.
Advisories And Exploit References
- advisoryhttps://security.alpinelinux.org/vuln/CVE-2020-7247
- advisoryhttps://security-tracker.debian.org/tracker/CVE-2020-7247
- advisoryhttps://ubuntu.com/security/CVE-2020-7247
- advisoryhttps://www.cve.org/CVERecord?id=CVE-2020-7247
- advisoryhttp://packetstormsecurity.com/files/162093/OpenBSD-OpenSMTPD-6.6-Remote-Code-Execution.html
- advisoryhttps://ftp.openbsd.org/pub/OpenBSD/patches/6.6/common/019_smtpd_exec.patch.sig
Description
smtp_mailaddr in smtp_session.c in OpenSMTPD 6.6, as used in OpenBSD 6.6 and other products, allows remote attackers to execute arbitrary commands as root via a crafted SMTP session, as demonstrated by shell metacharacters in a MAIL FROM field. This affects the "uncommented" default configuration. The issue exists because of an incorrect return value upon failure of input validation.
Known-Exploited Catalog Listings
| Catalog | Added | Remediation due | Ransomware use |
|---|---|---|---|
| CISA KEV | Mar 25, 2022 | Apr 15, 2022 | Not reported |
| Industry KEV feed | Mar 25, 2022 | Apr 15, 2022 | Not reported |
| CIRCL KEV | Mar 25, 2022 | Apr 15, 2022 | Not reported |
| ENISA EUVD | Mar 25, 2022 | n/a | Not reported |
Required action: Apply updates per vendor instructions.
Affected Products
40 affected entries in total| Product | Affected versions | Fixed in |
|---|---|---|
| OpensmtpdOpenbsd | 6.6 | 6.6.2p1-1 |
| Ubuntu LinuxCanonical | 18.04, 19.10 | n/a |
| Debian LinuxDebian | 10.0, 9.0 | n/a |
| FedoraFedoraproject | 32 | n/a |
Patched Releases
Opensmtpd
5.4.1p1-1ubuntu0.1~esm1, 5.7.3p2-1ubuntu0.1~esm1, 5.7.3p2-1ubuntu0.1~esm2, 6.0.2p1-2+deb9u2, 6.0.3p1-1ubuntu0.1, 6.0.3p1-5+deb10u3, 6.6.2_p1-r0, 6.6.2p1-1, 6.6.2p1-r0
Timeline
Publicly disclosed
Jan 29, 2020
Added to CISA KEV
Mar 25, 2022
Added to Industry KEV feed
Mar 25, 2022
Added to CIRCL KEV
Mar 25, 2022
Added to ENISA EUVD
Mar 25, 2022
Last updated
Nov 29, 2026
Weakness Type
- CWE-78 Improper Neutralization of Special Elements used in an OS Command
- CWE-755 Improper Handling of Exceptional Conditions
References
- advisorysecurity.alpinelinux.org · CVE-2020-7247
- advisorysecurity-tracker.debian.org · CVE-2020-7247
- advisoryubuntu.com · CVE-2020-7247
- advisorycve.org · CVERecord
- advisorypacketstormsecurity.com · OpenBSD-OpenSMTPD-6.6-Remote-Code-Execution.html
FAQ
Common Questions.
smtp_mailaddr in smtp_session.c in OpenSMTPD 6.6, as used in OpenBSD 6.6 and other products, allows remote attackers to execute arbitrary commands as root via a crafted SMTP session, as demonstrated by shell metacharacters in a MAIL FROM field.
Affected: Opensmtpd (Openbsd) versions 6.6; Ubuntu Linux (Canonical) versions 18.04, 19.10; Debian Linux versions 10.0, 9.0, among others. The full list is in the CVE brief.
It is exploited in the wild, listed in CISA KEV, Industry KEV feed, CIRCL KEV, ENISA EUVD since Mar 25, 2022.
Yes. It was added on Mar 25, 2022 with a federal remediation due date of Apr 15, 2022.
A public exploit is reported by tracking sources, but no code link is listed yet.
Fixed versions are available, including Opensmtpd 5.4.1p1-1ubuntu0.1~esm1, Opensmtpd 5.7.3p2-1ubuntu0.1~esm1, Opensmtpd 5.7.3p2-1ubuntu0.1~esm2.
Brandefense priority: patch immediately, because it is listed as exploited in the wild.
Is CVE-2020-7247 On Your Attack Surface?
Brandefense matches it against the products discovered on your perimeter and opens a finding the day a CVE like this is listed.
Request A Demo