# CVE-2021-34551: Remote Code Execution vulnerability in PHPMailer 6.4.1 running on Windows

- Severity: High 8.1 (CVSS:3.1, scored by NVD) `CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 2.80%, higher than 86% of CVEs (2026-12-01)
- Published: 2021-06-16T17:23:18.000Z
- Modified: 2026-09-08T08:48:24.829Z
- Also known as: GHSA-7q44-r25x-wm4q, BIT-PHPMAILER-2021-34551
- Weaknesses: CWE-94, CWE-434
- Assigned by: mitre

## Description

PHPMailer before 6.5.0 on Windows allows remote code execution if lang_path is untrusted data and has a UNC pathname.

(As written by CVE List.)

## Affected

- Unspecified product: n/a
- phpmailer/phpmailer (Packagist): before 6.5.0
- phpmailer_project phpmailer: before 6.5.0
- fedoraproject fedora: 33; 34
- phpmailer (Bitnami): before 6.5.0

## Every score

- GitHub: CVSS:3.1 8.1 High `CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:3.1 8.1 High `CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:2.0 5.1 Medium `AV:N/AC:H/Au:N/C:P/I:P/A:P`
- Bitnami Vulnerability Database: rating High

## References

- <https://github.com/PHPMailer/PHPMailer/blob/master/SECURITY.md> (advisory, issue-tracking, third-party-advisory, web)
- <https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/FJYSOFCUBS67J3TKR74SD3C454N7VTYM/> (vendor-advisory, web)
- <https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/3YRMWGA4VTMXFB22KICMB7YMFZNFV3EJ/> (vendor-advisory, web)
- <https://github.com/PHPMailer/PHPMailer/security/advisories/GHSA-7q44-r25x-wm4q> (web)
- <https://nvd.nist.gov/vuln/detail/CVE-2021-34551> (advisory, web)
- <https://github.com/PHPMailer/PHPMailer/commit/acd264bf17ff4ac5c915f0d4226dce8a9ea70bc3> (web)
- <https://github.com/FriendsOfPHP/security-advisories/blob/master/phpmailer/phpmailer/CVE-2021-34551.yaml> (web)
- <https://github.com/PHPMailer/PHPMailer/releases/tag/v6.5.0> (web)
- <https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/3YRMWGA4VTMXFB22KICMB7YMFZNFV3EJ> (web)
- <https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/FJYSOFCUBS67J3TKR74SD3C454N7VTYM> (web)

## Sources

- CVE List: [CVE-2021-34551](https://www.cve.org/CVERecord?id=CVE-2021-34551), CVE Terms of Use, modified 2024-08-04
- GitHub Advisory Database: [GHSA-7q44-r25x-wm4q](https://github.com/advisories/GHSA-7q44-r25x-wm4q), CC-BY-4.0, modified 2024-02-17
- NVD: [CVE-2021-34551](https://nvd.nist.gov/vuln/detail/CVE-2021-34551), Public domain, modified 2026-06-17
- Bitnami Vulnerability Database: [BIT-PHPMAILER-2021-34551](https://osv.dev/vulnerability/BIT-PHPMAILER-2021-34551), Apache-2.0, modified 2026-09-08

---

Page: https://cve.day/CVE-2021-34551 · Whole record: https://cve.day/CVE-2021-34551.json · Rebuilt by cve.day 2026-11-25T22:58:01.959Z
