Description
PHPMailer 5.2.23 has XSS in the "From Email Address" and "To Email Address" fields of code_generator.php.
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | libphp-phpmailer | 6.0.6-0.1 | — |
| Debian 13 | libphp-phpmailer | 6.0.6-0.1 | — |
| Debian 12 | libphp-phpmailer | 6.0.6-0.1 | — |
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu Pro 22.04 LTS | libphp-phpmailer | 6.2.0-2ubuntu0.1~esm1 | USN-5956-1 |
| Ubuntu Pro 20.04 LTS | libphp-phpmailer | 6.0.6-0.1ubuntu0.1~esm1 | USN-5956-1 |
| Ubuntu Pro 18.04 LTS | libphp-phpmailer | 5.2.14+dfsg-2.3+deb9u2ubuntu0.1~esm2 | USN-5956-2, USN-5956-1 |
Show 1 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu Pro 16.04 LTS | libphp-phpmailer | 5.2.14+dfsg-1ubuntu0.1~esm2 | USN-5956-2, USN-5956-1 |
Public exploits
Exploit or proof-of-concept code for this vulnerability is publicly available, which lowers the bar for attackers. Treat it as a reason to patch sooner.
GitHub 1 repository
-
wizardafric/download ★ 0 · Mar 26, 2018
(https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2017-11503
Sources: PoC-in-GitHub, Metasploit Framework, Exploit-DB — updated daily. Only links are listed; no exploit code is hosted here.
Affected packages
| Ecosystem | Package | Affected | Fixed | Record |
|---|---|---|---|---|
| Packagist | phpmailer/phpmailer | >= 5.0.0, < 5.2.24 | 5.2.24 | GHSA-58mj-pw57-4vm2 |
Advisories 2
- USN-5956-1 libphp-phpmailer vulnerabilities Ubuntu Security Notices (USN) · Jun 25, 2026
- USN-5956-2 libphp-phpmailer vulnerability Ubuntu Security Notices (USN) · Jun 25, 2026