Remote code execution in Exim

Published: 2017-11-28 | Updated: 2018-02-05
Risk High
Patch available YES
Number of vulnerabilities 1
CVE-ID CVE-2017-16943
Exploitation vector Network
Public exploit N/A
Vulnerable software
Server applications / Mail servers

Vendor Exim

Security Bulletin

This security bulletin contains one high risk vulnerability.

1) Use-after-free error


Risk: High


CVE-ID: CVE-2017-16943

CWE-ID: CWE-416 - Use After Free

Exploit availability: No


The vulnerability allows a remote attacker to execute arbitrary code on the target system.

The weakness exists due to a use-after-free memory error in the ESMTP CHUNKING extension within the receive_msg() function in receive.c. A remote attacker can connect to the SMTP service, send a specially crafted BDAT command, trigger memory corruption and execute arbitrary code on the target system.

Successful exploitation of the vulnerability may result in system compromise.


Update to version 4.90.

The vendor has described a workaround:

".. in the main section of your Exim configuration, set:

chunking_advertise_hosts =

This disables advertising the ESMTP CHUNKING extension, making the BDAT verb unavailable and avoids letting an attacker apply the logic."

Vulnerable software versions

Exim: 4.88 - 4.89

CPE2.3 External links

Q & A

Can this vulnerability be exploited remotely?

How the attacker can exploit this vulnerability?

Is there known malware, which exploits this vulnerability?