CVE-2020-7247
OpenSMTPD Remote Code Execution Vulnerability
- Actively exploited
- Critical · 9.8 of 10
- Exploited since
- 25 Mar 2022 added to the CISA list
- Chance of attacks
- 99% in the next 30 days (FIRST EPSS)
- Fix deadline
- 15 Apr 2022 for US federal agencies
- Published
- 29 Jan 2020 in the NVD
What this means
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.
CISA
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.
NIST National Vulnerability Database
What to do
Apply updates per vendor instructions.
CISA's required action. If you use the product, install the vendor's update as soon as possible.
Affected
- n/a n/a
Official sources
- nvd.nist.gov/vuln/detail/CVE-2020-7247
- openbsd.org/security.html vendor advisory
- packetstormsecurity.com/files/156137/OpenBSD-OpenSMTPD-Privilege-Escalation-Code-Execution...
- packetstormsecurity.com/files/156145/OpenSMTPD-6.6.2-Remote-Code-Execution.html
- packetstormsecurity.com/files/156249/OpenSMTPD-MAIL-FROM-Remote-Code-Execution.html
- packetstormsecurity.com/files/156295/OpenSMTPD-6.6.1-Local-Privilege-Escalation.html
- packetstormsecurity.com/files/162093/OpenBSD-OpenSMTPD-6.6-Remote-Code-Execution.html
- seclists.org/fulldisclosure/2020/Jan/49
- openwall.com/lists/oss-security/2020/01/28/3
Data from the NIST National Vulnerability Database, the CISA Known Exploited Vulnerabilities list, FIRST EPSS and ENISA, checked 18 Nov 2026. CVSS vector CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H.