CVE-2017-5223 Local file disclosure in PHPMailer
MediumCVSS 5.5
EPSS 2.1%
Public exploit
PoC
- Published
- Updated
- Exploit status
- Public exploit available
Description
An issue was discovered in PHPMailer before 5.2.22. PHPMailer's msgHTML method applies transformations to an HTML document to make it usable as an email message body. One of the transformations is to convert relative image URLs into attachments using a script-provided base directory. If no base directory is provided, it resolves to /, meaning that relative image URLs get treated as absolute local file paths and added as attachments. To form a remote vulnerability, the msgHTML method must be called, passed an unfiltered, user-supplied HTML document, and must not set a base directory.
Affected products
| Product | Affected versions | Fixed in |
|---|---|---|
| phpmailer/phpmailer(Packagist) | >= 5.0.0, < 5.2.22 | 5.2.22 |
| phpmailer/phpmailer(Packagist) | = v5.2.10 | No fix listed |
| phpmailer/phpmailer(Packagist) | = v5.2.11 | No fix listed |
| phpmailer/phpmailer(Packagist) | = v5.2.12 | No fix listed |
| phpmailer/phpmailer(Packagist) | = v5.2.13 | No fix listed |
| phpmailer/phpmailer(Packagist) | = v5.2.14 | No fix listed |
| phpmailer/phpmailer(Packagist) | = v5.2.15 | No fix listed |
| phpmailer/phpmailer(Packagist) | = v5.2.16 | No fix listed |
| phpmailer/phpmailer(Packagist) | = v5.2.17 | No fix listed |
| phpmailer/phpmailer(Packagist) | = v5.2.18 | No fix listed |
| phpmailer/phpmailer(Packagist) | = v5.2.19 | No fix listed |
| phpmailer/phpmailer(Packagist) | = v5.2.2 | No fix listed |
| phpmailer/phpmailer(Packagist) | = v5.2.20 | No fix listed |
| phpmailer/phpmailer(Packagist) | = v5.2.21 | No fix listed |
| phpmailer/phpmailer(Packagist) | = v5.2.4 | No fix listed |
| phpmailer/phpmailer(Packagist) | = v5.2.5 | No fix listed |
| phpmailer/phpmailer(Packagist) | = v5.2.6 | No fix listed |
| phpmailer/phpmailer(Packagist) | = v5.2.7 | No fix listed |
| phpmailer/phpmailer(Packagist) | = v5.2.8 | No fix listed |
| phpmailer/phpmailer(Packagist) | = v5.2.9 | No fix listed |
| debian/libphp-phpmailer(Debian:12) | < 5.2.14+dfsg-2.3 | 5.2.14+dfsg-2.3 |
| debian/libphp-phpmailer(Debian:14) | < 5.2.14+dfsg-2.3 | 5.2.14+dfsg-2.3 |
| debian/libphp-phpmailer(Debian:13) | < 5.2.14+dfsg-2.3 | 5.2.14+dfsg-2.3 |
| phpmailer project phpmailer | <= 5.2.21 | No fix listed |
References
- github.com vendor-advisory
- github.com exploit
- github.com
- nvd.nist.gov third-party-advisory vendor-advisory
- github.com issue-tracking patch third-party-advisory
- 43056 exploit
- kalilinux.co exploit third-party-advisory
- 95328 third-party-advisory vdb-entry
- github.com
- Debian Security Tracker CVE-2017-5223 vendor-advisory
- bugs.debian.org issue-tracking