CVE-2020-7247
CONFIRMED EXPLOITEDOpenSMTPD Remote Code Execution Vulnerability
Is OpenBSD OpenSMTPD affected by CVE-2020-7247?
OpenBSD OpenSMTPD is listed in the CISA Known Exploited Vulnerabilities catalog for CVE-2020-7247, added on 2022-03-25. CISA only adds a CVE once it has evidence of exploitation in the wild, so the patching question is not whether it can be attacked but how soon your instances must be updated.
Affected products published by NIST NVD (6 vulnerable CPE entries): canonical ubuntu_linux, debian debian_linux, fedoraproject fedora and openbsd opensmtpd.
Published CPE data pins the vulnerable releases as 6.6, 9.0, 10.0, 18.04, 19.10 and 32. Check the vendor advisory below for the fixed release and for any other affected build.
The CISA remediation deadline for this entry is 2022-04-15.
RELATED VULNERABILITY DOSSIERS
Other catalog entries that share this product, vendor, or weakness, or that sit next to this advisory in the CISA KEV timeline.
- CVE-2026-123158Same vendorOpenBSD OpenSSH
OpenBSD OpenSSH Unexpected Status Code or Return Value Vulnerability
- CVE-2024-6387Same vendorOpenBSD OpenSSH
OpenSSH Server (sshd) Signal Handler Race Condition (regreSSHion)
- CVE-2026-133323Shared weaknessMitel MiCollab
Mitel MiCollab OS Command Injection Vulnerability
- CVE-2026-103406Shared weaknessHewlett Packard Enterprise (HPE) Juniper Session Smart Conductor and Session Smart Router
Hewlett Packard Enterprise (HPE) Juniper Session Smart Conductor and Session Smart Router OS Command Injection Vulnerability
- CVE-2020-5410Neighboring entryVMware Tanzu Spring Cloud Configuration (Config) Server
VMware Tanzu Spring Cloud Config Directory Traversal Vulnerability
- CVE-2020-9054Neighboring entryZyxel Multiple Network-Attached Storage (NAS) Devices
Zyxel Multiple NAS Devices OS Command Injection Vulnerability
1. VULNERABILITY OVERVIEW & TECHNICAL MECHANISM
smtp_mailaddr in smtp_session.c in OpenSMTPD, as used in OpenBSD and other products, allows remote attackers to execute arbitrary commands as root via a crafted SMTP session.
Get Stack Watch email when a KEV hits your stack ($99/year or $12/month)
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.
2. AFFECTED VERSIONS, PRODUCTS & VERIFIED CPE CONFIGURATIONS
3. EXPLOITATION EVIDENCE, IMPACT & HOW TO DETECT IT
This vulnerability was added to the CISA Known Exploited Vulnerabilities (KEV) catalog on 2022-03-25. Inclusion in KEV requires verified evidence of active exploitation in the wild. Known ransomware campaign use is recorded by CISA as: "Unknown".
Note: KEV inclusion confirms that threat actors have exploited this flaw in real-world incidents; it does not imply every deployment of OpenSMTPD has been compromised.
- CVSS vector indicates high impact to Confidentiality (C:H), Integrity (I:H), and Availability (A:H) of the affected component.
- Network service surface (OpenBSD OpenSMTPD): inspect perimeter and internal flow telemetry (`Zeek conn.log`, `Suricata eve.json`) and host service logs for anomalous connection bursts, protocol errors, or unexpected child processes.
- Command/Argument Injection class (CWE-77/78/88): monitor process trees for `/bin/sh`, `bash`, `cmd.exe`, `powershell`, `curl`, or `wget` spawned as child processes of the service daemon.
- Authentication / status-handling weakness: audit service authentication logs for session establishment without complete challenge verification, unexpected return-code handling, or spikes in aborted auth handshakes.
- Inventory all hosts running OpenBSD OpenSMTPD and compare installed package/build versions against the NVD CPE configurations and vendor advisory below.
4. FIXED VERSION, MITIGATIONS & OFFICIAL ADVISORY CITATIONS
Apply updates per vendor instructions.
- http://packetstormsecurity.com/files/156137/OpenBSD-OpenSMTPD-Privilege-Escalation-Code-Execution.htmlExploitThird Party AdvisoryVDB Entry
- http://packetstormsecurity.com/files/156145/OpenSMTPD-6.6.2-Remote-Code-Execution.htmlExploitThird Party AdvisoryVDB Entry
- http://packetstormsecurity.com/files/156249/OpenSMTPD-MAIL-FROM-Remote-Code-Execution.htmlExploitThird Party AdvisoryVDB Entry
- http://packetstormsecurity.com/files/156295/OpenSMTPD-6.6.1-Local-Privilege-Escalation.htmlExploitThird Party AdvisoryVDB Entry
- http://packetstormsecurity.com/files/162093/OpenBSD-OpenSMTPD-6.6-Remote-Code-Execution.htmlBroken LinkThird Party AdvisoryVDB Entry
- http://seclists.org/fulldisclosure/2020/Jan/49ExploitMailing ListThird Party Advisory
- http://www.openwall.com/lists/oss-security/2020/01/28/3ExploitMailing ListThird Party Advisory
- https://github.com/openbsd/src/commit/9dcfda045474d8903224d175907bfc29761dcb45Patch
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/OPH4QU4DNVHA7ACFXMYFCEP5PSXXPN4E/Mailing ListThird Party Advisory
- https://seclists.org/bugtraq/2020/Jan/51Mailing ListThird Party Advisory
- https://usn.ubuntu.com/4268-1/Third Party Advisory
- https://www.debian.org/security/2020/dsa-4611Mailing ListThird Party Advisory
- https://www.kb.cert.org/vuls/id/390745Third Party AdvisoryUS Government Resource
- https://www.openbsd.org/security.htmlPatchVendor Advisory
- http://packetstormsecurity.com/files/156137/OpenBSD-OpenSMTPD-Privilege-Escalation-Code-Execution.htmlExploitThird Party AdvisoryVDB Entry
- http://packetstormsecurity.com/files/156145/OpenSMTPD-6.6.2-Remote-Code-Execution.htmlExploitThird Party AdvisoryVDB Entry
- http://packetstormsecurity.com/files/156249/OpenSMTPD-MAIL-FROM-Remote-Code-Execution.htmlExploitThird Party AdvisoryVDB Entry
- http://packetstormsecurity.com/files/156295/OpenSMTPD-6.6.1-Local-Privilege-Escalation.htmlExploitThird Party AdvisoryVDB Entry
- http://packetstormsecurity.com/files/162093/OpenBSD-OpenSMTPD-6.6-Remote-Code-Execution.htmlBroken LinkThird Party AdvisoryVDB Entry
- http://seclists.org/fulldisclosure/2020/Jan/49ExploitMailing ListThird Party Advisory
- http://www.openwall.com/lists/oss-security/2020/01/28/3ExploitMailing ListThird Party Advisory
- https://github.com/openbsd/src/commit/9dcfda045474d8903224d175907bfc29761dcb45Patch
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/OPH4QU4DNVHA7ACFXMYFCEP5PSXXPN4E/Mailing ListThird Party Advisory
- https://seclists.org/bugtraq/2020/Jan/51Mailing ListThird Party Advisory
- https://usn.ubuntu.com/4268-1/Third Party Advisory
SCORING & VECTOR TELEMETRY
Primary assessment authored by NIST NVD (nvd@nist.gov).
EPSS estimates the statistical probability of exploitation activity in the next 30 days—it is not proof of confirmed exploitation.
RELEVANT DEFENSIVE TOOLS
Curated open-source defensive and verification utilities from The Loot applicable to this asset class:
Endpoint visibility, digital forensics, and incident response (DFIR) platform
Network security monitoring (NSM) and protocol metadata extraction framework
Multi-threaded IDS, IPS, and network security monitoring engine
VirusTotal's memory-safe Rust rewrite of YARA for binary & implant hunting