Improper Encoding or Escaping of Output in PHPMailer - #VU173510

 

Improper Encoding or Escaping of Output in PHPMailer - #VU173510

Published: December 4, 2026


Vulnerability identifier: #VU173510
CSH Severity: Medium
CVSS v4: 6.9 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N]
CVE-ID: N/A
CWE-ID: CWE-116
Exploitation vector: Remote access
Exploit availability: No public exploit available

Vulnerability details

The vulnerability allows a remote attacker to bypass email attachment filters that rely on filename extensions.

The vulnerability exists due to improper escaping of backslashes in PHPMailer's quotedString() function when formatting untrusted attachment names for MIME headers. A remote attacker can supply a malformed attachment name that introduces a second filename parameter in the Content-Type or Content-Disposition header to bypass extension-based filtering.


Affected software

PHPMailer

Remediation

Install security update from vendor's website.

PHPMailer - update to 7.4.0

External References

Related Security Bulletins