Search for packages
purl | pkg:composer/phpmailer/phpmailer@6.4.1 |
Vulnerability | Summary | Fixed by |
---|---|---|
VCID-377c-stcv-abgs
Aliases: CVE-2021-3603 GHSA-77mr-wc79-m8j3 |
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. |
Affected by 0 other vulnerabilities. |
VCID-x7mu-d5zc-zkbx
Aliases: CVE-2021-34551 GHSA-7q44-r25x-wm4q |
Remote Code Execution vulnerability in PHPMailer 6.4.1 running on Windows PHPMailer 6.4.1 contains a possible remote code execution vulnerability through the `$lang_path` parameter of the `setLanguage()` method. If the `$lang_path` parameter is passed unfiltered from user input, it can be set to [a UNC path](https://docs.microsoft.com/en-us/dotnet/standard/io/file-path-formats#unc-paths), and if an attacker is also able to create a remote mount on the server that the UNC path points to, a script file under their control may be executed. ### Impact Arbitrary code may be run by a remote attacker under the web server or PHP process running on Window hosts. ### Patches Mitigated in PHPMailer 6.5.0 by no longer treating translation files as PHP code, but by parsing their text content directly. This approach avoids the possibility of executing unknown code while retaining backward compatibility. This isn't ideal, so the current translation format is deprecated and will be replaced in the next major release. ### Workarounds Any of: * Ensure that calling code does not pass unfiltered user-supplied data to the `$lang_path` parameter of the `setLanguage()` method. * Block or filter the use of unknown UNC paths in this parameter (or altogether). * Ensure that unauthorised users do not have the ability to read from unknown remote servers via UNC paths. * Run on an OS that does not support UNC paths ### References [CVE-2021-34551](https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2021-34551). Reported by [listensec.com](https://listensec.com) via Tidelift. ### For more information If you have any questions or comments about this advisory: * Open an issue in [PHPMailer](https://github.com/PHPMailer/PHPMailer) * [Email the maintainers](mailto:phpmailer@synchromedia.co.uk) |
Affected by 0 other vulnerabilities. |
Vulnerability | Summary | Aliases |
---|---|---|
VCID-vqjk-32b7-zkgz | Object injection in PHPMailer/PHPMailer ### Impact This is a reintroduction of an earlier issue (CVE-2018-19296) by an unrelated bug fix in PHPMailer 6.1.8. An external file may be unexpectedly executable if it is used as a path to an attachment file via PHP's support for `.phar` files`. Exploitation requires that an attacker is able to provide an unfiltered path to a file to attach, or to trick calling code into generating one. See [this article](https://knasmueller.net/5-answers-about-php-phar-exploitation) for more info. ### Patches This issue was patched in the PHPMailer 6.4.1 release. This release also implements stricter filtering for attachment paths; paths that look like *any* kind of URL are rejected. ### Workarounds Validate paths to loaded files using the same pattern as used in [`isPermittedPath()`](https://github.com/PHPMailer/PHPMailer/blob/master/src/PHPMailer.php#L1815) before using them in *any* PHP file function, such as `file_exists`. This method can't be used directly because it is protected, but you can implement the same thing in calling code. Note that this should be applied to *all* user-supplied paths passed into such functions; it's not a problem specific to PHPMailer. ### Credit This issue was found by Fariskhi Vidyan, reported and managed via Tidelift. |
CVE-2020-36326
GHSA-m298-fh5c-jc66 |