CVE-2018-6789: Exim Buffer Overflow Vulnerability
CVE-2018-6789 is a critical-severity flaw (CVSS 9.8) affecting exim, debian linux, ubuntu linux, reported as exploited in the wild. Below: why it ranks where it does, which versions are affected, what to do, and the exact commands.
An issue was discovered in the base64d function in the SMTP listener in Exim before 4.90.1. By sending a handcrafted message, a buffer overflow may happen. This can be used to execute code remotely.
Why this priority
- Critical severity
- EPSS top 1%: very likely to be exploited
- Exploited in the wild (CISA KEV)
- Used in ransomware campaigns
- Public exploit reference
- CISA SSVC: automatable with total technical impact
- Remotely exploitable, no login, no user action
- On your watchlist
A fixed release or distro patch exists.
Risk facts
| CVSS score | 9.8 (Critical) |
| Attack vector | Network (remote) |
| Attack complexity | Low |
| Privileges needed | None |
| User interaction | None |
| EPSS exploit chance | 82.1% (top 1%) |
| CISA exploited list | Yes, fix due 2022-05-03, used in ransomware |
| Weakness | CWE-120 |
| Published | 2018-02-08 |
| Last modified | 2026-06-17 |
Last updated 2026-06-17 · Sources: CVE Program, NVD, CISA KEV, EPSS and vendor advisories · How we score
Am I affected?
Timeline
- Published CVE record published
- Exploited Added to the CISA Known Exploited Vulnerabilities list
- Deadline CISA due date for US federal agencies to patch
- Updated Record last modified
Exact fixes by distribution
Public exploits and detection
Public code exists for this CVE. Treat unpatched systems as at risk, and only run PoCs in a lab.
- GitHub PoC: martinclauss/exim-rce-cve-2018-6789 (11 stars)
- GitHub PoC: synacktiv/Exim-CVE-2018-6789 (10 stars)
- GitHub PoC: beraphin/CVE-2018-6789 (3 stars)
- Write-up: www.exploit-db.com/exploits/44571/
- Write-up: www.exploit-db.com/exploits/45671/
- Exploit-DB: exim 4.90 - Remote Code Execution
- Exploit-DB: Exim < 4.90.1 - 'base64d' Remote Code Execution
Scores and fixes here are computed automatically from those and other public sources. Confirm with the vendor advisory before changing production systems.
Quick answers
How do I fix CVE-2018-6789?
exim: upgrade to 4.90.1; debian linux: mitigate or apply the listed mitigation; ubuntu linux: mitigate or apply the listed mitigation. Exact commands for each OS are on this page.
Is CVE-2018-6789 being exploited?
Yes. CVE-2018-6789 is on the CISA Known Exploited Vulnerabilities list, so treat it as patch-now.
What does CVE-2018-6789 affect?
CVE-2018-6789 affects exim, debian linux, ubuntu linux. Severity is critical (CVSS 9.8). An issue was discovered in the base64d function in the SMTP listener in Exim before 4.90.1. By sending a handcrafted message, a buffer overflow may happen. This can be used to execute code remotely.
How urgent is CVE-2018-6789?
Priority 100/100. Critical severity; EPSS top 1%: very likely to be exploited; Exploited in the wild (CISA KEV); Used in ransomware campaigns; Public exploit reference; CISA SSVC: automatable with total technical impact; Remotely exploitable, no login, no user action; On your watchlist
Software pages
Ubuntu vulnerabilities · Debian vulnerabilities · Exim vulnerabilities
Related CVEs
- CVE-2025-67896 HIGH 7.0 UPGRADE Exim before 4.99.1, with certain non-default rate-limit configurations, allows a remote heap-based buffer over
- CVE-2026-94054 HIGH 7.0 UPGRADE Exim before 4.100.1, when Proxy-Protocol is used with an attacker-controlled proxy, has an out-of-bounds write
- CVE-2026-94055 LOW 3.7 UPGRADE Exim before 4.100.1, when certain non-default TLS settings are used with GnuTLS, has a use-after-free.
- CVE-2026-94056 HIGH 7.5 UPGRADE Exim before 4.100.1, when Proxy-Protocol is used with an attacker-controlled proxy, allows attackers to read c
- CVE-2026-94057 MEDIUM 4.0 UPGRADE Exim before 4.100.1 allows SMTP smuggling in which the received message does not match any sent message, and i