{"id":"GHSA-58mj-pw57-4vm2","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.\n\n### Impact\nPHPMailer 5.2.23 has XSS in the &quot;From Email Address&quot; and &quot;To Email Address&quot; fields of code_generator.php.\n\n### Patches\nFixed in 5.2.24\n\n### Workarounds\nNone.\n\n### References\nhttps://nvd.nist.gov/vuln/detail/CVE-2017-11503\n\n### For more information\nIf you have any questions or comments about this advisory:\n* Open a private issue in [the PHPMailer project](https://github.com/PHPMailer/PHPMailer)","aliases":["CVE-2017-11503"],"modified":"2024-02-16T05:19:30.320222Z","published":"2020-03-05T22:09:13Z","database_specific":{"github_reviewed_at":"2020-03-05T22:06:39Z","nvd_published_at":null,"cwe_ids":["CWE-79"],"severity":"MODERATE","github_reviewed":true},"references":[{"type":"WEB","url":"https://github.com/PHPMailer/PHPMailer/security/advisories/GHSA-58mj-pw57-4vm2"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2017-11503"},{"type":"WEB","url":"https://cxsecurity.com/issue/WLB-2017060181"},{"type":"WEB","url":"https://github.com/FriendsOfPHP/security-advisories/blob/master/phpmailer/phpmailer/CVE-2017-11503.yaml"},{"type":"WEB","url":"https://github.com/PHPMailer/PHPMailer/releases/tag/v5.2.24"},{"type":"WEB","url":"https://packetstormsecurity.com/files/143138/phpmailer-xss.txt"},{"type":"WEB","url":"http://www.securityfocus.com/bid/99293"},{"type":"WEB","url":"http://www.securitytracker.com/id/1039026"}],"affected":[{"package":{"name":"phpmailer/phpmailer","ecosystem":"Packagist","purl":"pkg:composer/phpmailer/phpmailer"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"5.0.0"},{"fixed":"5.2.24"}]}],"versions":["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.2","v5.2.20","v5.2.21","v5.2.22","v5.2.23","v5.2.4","v5.2.5","v5.2.6","v5.2.7","v5.2.8","v5.2.9"],"database_specific":{"source":"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2020/03/GHSA-58mj-pw57-4vm2/GHSA-58mj-pw57-4vm2.json"}}],"schema_version":"1.9.0","severity":[{"type":"CVSS_V3","score":"CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N"}]}