Vulnerability · Published May 3, 2024 · Assigned by zdi
CVE-2023-42118Exim libspf2 Integer Underflow Remote Code Execution Vulnerability
High 7.5
In plain English
A high-severity security flaw in libspf2 from Exim. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 8.4% (higher than 95% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.
Official description
Exim libspf2 Integer Underflow Remote Code Execution Vulnerability. This vulnerability allows network-adjacent attackers to execute arbitrary code on affected installations of Exim libspf2. Authentication is not required to exploit this vulnerability. The specific flaw exists within the parsing of SPF macros. When parsing SPF macros, the process does not properly validate user-supplied data, which can result in an integer underflow before writing to memory. An attacker can leverage this vulnerability to execute code in the context of the service account. . Was ZDI-CAN-17578.
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| Alpine:v3.20 | libspf2 | 1.2.11-r3 | ALPINE-CVE-2023-42118 |
| Alpine:v3.21 | libspf2 | 1.2.11-r3 | ALPINE-CVE-2023-42118 |
| Alpine:v3.22 | libspf2 | 1.2.11-r3 | ALPINE-CVE-2023-42118 |
| Alpine:v3.23 | libspf2 | 1.2.11-r3 | ALPINE-CVE-2023-42118 |
| Alpine:v3.24 | libspf2 | 1.2.11-r3 | ALPINE-CVE-2023-42118 |
| Debian:12 | libspf2 | no fix listed | DEBIAN-CVE-2023-42118 |
| Debian:13 | libspf2 | no fix listed | DEBIAN-CVE-2023-42118 |
| Debian:14 | libspf2 | no fix listed | DEBIAN-CVE-2023-42118 |
| Ubuntu:22.04:LTS | exim4 | no fix listed | UBUNTU-CVE-2023-42118 |
| Ubuntu:24.04:LTS | exim4 | no fix listed | UBUNTU-CVE-2023-42118 |
| Ubuntu:25.10 | exim4 | no fix listed | UBUNTU-CVE-2023-42118 |
| Ubuntu:26.04:LTS | exim4 | no fix listed | UBUNTU-CVE-2023-42118 |
| Ubuntu:26.10 | exim4 | no fix listed | UBUNTU-CVE-2023-42118 |
| Ubuntu:22.04:LTS | libspf2 | no fix listed | UBUNTU-CVE-2023-42118 |
| Ubuntu:24.04:LTS | libspf2 | no fix listed | UBUNTU-CVE-2023-42118 |
| Ubuntu:25.10 | libspf2 | no fix listed | UBUNTU-CVE-2023-42118 |
| Ubuntu:26.04:LTS | libspf2 | no fix listed | UBUNTU-CVE-2023-42118 |
| Ubuntu:26.10 | libspf2 | no fix listed | UBUNTU-CVE-2023-42118 |
Affected products (as reported)
Weakness: CWE-191 · Vector: CVSS:3.0/AV:A/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
References
- ZDI-23-1472 x_research-advisory
- http://www.openwall.com/lists/oss-security/2025/03/28/1