Arbitrary Code Execution Affecting phpmailer/phpmailer package, versions <6.5.0


Severity

Recommended
0.0
critical
0
10

CVSS assessment made by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
0.34% (73rd percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications

Snyk Learn

Learn about Arbitrary Code Execution vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-PHP-PHPMAILERPHPMAILER-1311001
  • published17 Jun 2021
  • disclosed17 Jun 2021
  • creditVikrant Singh Chauhan

Introduced: 17 Jun 2021

CVE-2021-3603  (opens in a new tab)
CWE-94  (opens in a new tab)

How to fix?

Upgrade phpmailer/phpmailer to version 6.5.0 or higher.

Overview

Affected versions of this package are vulnerable to Arbitrary Code Execution. 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.

References

CVSS Scores

version 3.1