CVE-2021-3603 json
Inclusion of Functionality from Untrusted Control Sphere in PHPMailer/PHPMailer
published 5y ago modified 2mo ago also BIT-phpmailer-2021-3603 , EUVD-2021-1277 , GHSA-77mr-wc79-m8j3
- cvss
- 8.1
- version 3.1, CNA
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 2.3%
- EPSS 2.3% chance of exploitation in 30 days, percentile 83%
- public exploits
- 0
- none known
Summary
PHPMailer 6.4.1 and earlier contain a vulnerability that can result in untrusted code being called (if such code is injected into the host project's scope by other means). If the $patternselect parameter to validateAddress() is set to 'php' (the default, defined by PHPMailer::$validator), and the global namespace contains a function called php, it will be called in preference to the built-in validator of the same name. Mitigated in PHPMailer 6.5.0 by denying the use of simple strings as validator function names.
Patch / fix
- packagist phpmailer/phpmailer 6.5.0
- bitnami phpmailer 6.4.2
- PHPMailer PHPMailer 6.5.0
- libphp-phpmailer Debian 14, Debian 13, Debian 12 6.6.3-1
debian advisories DEBIAN-CVE-2021-3603
- libphp-phpmailer Ubuntu Pro 20.04 LTS 6.0.6-0.1ubuntu0.1~esm1
- libphp-phpmailer Ubuntu Pro 22.04 LTS 6.2.0-2ubuntu0.1~esm1
ubuntu advisories UBUNTU-CVE-2021-3603
Ubuntu security data © Canonical Ltd., from https://github.com/canonical/ubuntu-security-notices via OSV; changed: normalised to fixed package versions per release. CC BY-SA 4.0
Is CVE-2021-3603 in your dependencies? Fencer shows which of your repositories are affected as soon as an advisory lands, and opens the fix as a pull request.
Check with FencerVendor advisories
What the vendors themselves say about their products: affected, fixed or not affected, and what to do.
red hat product security vex CVE-2021-3603 updated cvss 8.1
php-PHPMailer: inclusion of functionality from untrusted control sphere vulnerability
-
Red Hat All currently supported Red Hat productsnot affected: vulnerable code not present
Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf
Exploit prediction
2.26% chance of exploitation in the next 30 days, higher than 83% of all scored CVEs (FIRST EPSS, 2026-11-09).
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| CNA | 3.1 | 8.1 | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H |
| GitHub | 3.1 | 8.1 | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H |
| NVD | 3.1 | 8.1 | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H |
| NVD | 2.0 | 6.8 | AV:N/AC:M/Au:N/C:P/I:P/A:P |
| OSV | 3.1 | 8.1 | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H |
Affected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| packagist | phpmailer/phpmailer | <6.5.0 |
6.5.0 |
| bitnami | phpmailer | <6.4.2 |
6.4.2 |
Affected products
- PHPMailer PHPMailer
Classification
References
-
github.com
/PHPMailer/PHPMailer/commit/45f3c18dc6a2de1cb1bf49b9b249a9ee36a5f7f3
web, patch, third-party-advisory, advisory
-
lists.fedoraproject.org
/archives/list/package-announce%40lists.fedoraproject.org/message/FJYSOFCUBS67J3TKR74SD3C454N7VTYM/
vendor-advisory, web
-
lists.fedoraproject.org
/archives/list/package-announce%40lists.fedoraproject.org/message/3YRMWGA4VTMXFB22KICMB7YMFZNFV3EJ/
vendor-advisory, web
-
huntr.dev
/bounties/1-PHPMailer/PHPMailer/
product, web
-
github.com
/PHPMailer/PHPMailer/security/advisories/GHSA-77mr-wc79-m8j3
web
-
nvd.nist.gov
/vuln/detail/CVE-2021-3603
advisory, web
-
github.com
/FriendsOfPHP/security-advisories/blob/master/phpmailer/phpmailer/CVE-2021-3603.yaml
web
-
github.com
/PHPMailer/PHPMailer
package
-
github.com
/PHPMailer/PHPMailer/releases/tag/v6.5.0
web
-
lists.fedoraproject.org
/archives/list/package-announce%40lists.fedoraproject.org/message/3YRMWGA4VTMXFB22KICMB7YMFZNFV3EJ
web
-
lists.fedoraproject.org
/archives/list/package-announce%40lists.fedoraproject.org/message/FJYSOFCUBS67J3TKR74SD3C454N7VTYM
web
-
web.nvd.nist.gov
/view/vuln/detail?vulnId=CVE-2021-3603
web
-
huntr.dev
/bounties/1-PHPMailer/PHPMailer
web
Sources
- CVE List CVE-2021-3603
- GitHub Advisory GHSA-77mr-wc79-m8j3
- NVD CVE-2021-3603
- OSV BIT-phpmailer-2021-3603
Fencer Intel keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.