KeygraphLabs · CVE MCP

CVE-2017-5223 · mitre

CVE-2017-5223

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.

Published 2017-01-16, last changed 2026-06-17. Weakness: CWE-200.

CVSS
5.5
medium, from NVD
EPSS
2.14%
percentile 82.7%, chance of exploitation in 30 days
Exploitation
Public exploit
1 public reference

Public exploits

SourceKindReference
exploit-dbproof-of-conceptEDB-43056

How to fix

Upgrade to a fixed version: phpmailer/phpmailer 5.2.22 (Packagist). For the version that clears every advisory for your installed version, ask an agent for get_remediation.

Timeline

2017-01-16Published
2020-03-05Package advisory GHSA-4x5h-cr29-fhp6
2026-06-17Record last changed
2026-11-30EPSS when our history starts: 2.14%

Affected packages

AdvisoryPackageFixed in
GHSA-4x5h-cr29-fhp6phpmailer/phpmailer (Packagist)5.2.22

Also known as: GHSA-4x5h-cr29-fhp6

Related

CVEPublishedCVSSSummary
CVE-2021-36032021-06-178.1Inclusion of Functionality from Untrusted Control Sphere in PHPMailer/PHPMailer
CVE-2021-345512021-06-168.1same package: phpmailer/phpmailer (Packagist)
CVE-2020-363262021-04-289.8same package: phpmailer/phpmailer (Packagist)
CVE-2020-136252020-06-087.5same package: phpmailer/phpmailer (Packagist)
CVE-2018-192962018-11-168.8same package: phpmailer/phpmailer (Packagist)
CVE-2017-115032017-07-206.1same package: phpmailer/phpmailer (Packagist)
CVE-2016-100452016-12-309.8same package: phpmailer/phpmailer (Packagist)
CVE-2016-10033 KEV2016-12-309.8same package: phpmailer/phpmailer (Packagist)

Add it to your agent

One command for Claude Code; setup for Claude Desktop, Cursor and others. No signup or key.

claude mcp add --transport http keygraph-cve https://cve-mcp.keygraph.io/mcp

Then ask for triage_cve CVE-2017-5223, or call /api/v1/vulnerabilities/CVE-2017-5223. To prove whether it is exploitable in your running app, run Shannon, Keygraph's open-source AI pentester.

NVD · CVE.org