GHSA-58mj-pw57-4vm2

Suggest an improvement
Source
https://github.com/advisories/GHSA-58mj-pw57-4vm2
Import Source
https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2020/03/GHSA-58mj-pw57-4vm2/GHSA-58mj-pw57-4vm2.json
JSON Data
https://api.osv.dev/v1/vulns/GHSA-58mj-pw57-4vm2
Aliases
Published
2020-03-05T22:09:13Z
Modified
2024-02-16T08:24:37.079984Z
Severity
  • 6.1 (Medium) CVSS_V3 - CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N CVSS Calculator
Summary
Cross-site scripting in PHPMailer
Details

PHPMailer versions prior to 5.2.24 (released July 26th 2017) have an XSS vulnerability in one of the code examples, CVE-2017-11503. The code_generator.phps example did not filter user input prior to output. This file is distributed with a .phps extension, so it it not normally executable unless it is explicitly renamed, and the file is not included when PHPMailer is loaded through composer, so it is safe by default. There was also an undisclosed potential XSS vulnerability in the default exception handler (unused by default). Patches for both issues kindly provided by Patrick Monnerat of the Fedora Project.

Impact

PHPMailer 5.2.23 has XSS in the "From Email Address" and "To Email Address" fields of code_generator.php.

Patches

Fixed in 5.2.24

Workarounds

None.

References

https://nvd.nist.gov/vuln/detail/CVE-2017-11503

For more information

If you have any questions or comments about this advisory: * Open a private issue in the PHPMailer project

References

Affected packages

Packagist / phpmailer/phpmailer

Package

Name
phpmailer/phpmailer
Purl
pkg:composer/phpmailer/phpmailer

Affected ranges

Type
ECOSYSTEM
Events
Introduced
5.0.0
Fixed
5.2.24

Affected versions

v5.*

v5.2.2
v5.2.4
v5.2.5
v5.2.6
v5.2.7
v5.2.8
v5.2.9
v5.2.10
v5.2.11
v5.2.12
v5.2.13
v5.2.14
v5.2.15
v5.2.16
v5.2.17
v5.2.18
v5.2.19
v5.2.20
v5.2.21
v5.2.22
v5.2.23