packagist package report

Is phpmailer/phpmailer safe?

14 known vulnerabilities, worst severity CRITICAL.

// reach

0 direct dependencies

none carry a known advisory

    0 packages depend on it

    dependents not yet indexed for this ecosystem

      Create a free accountfor every dependency path, dependent and what to upgrade
      // ai model usage

      Tracked for PyPI packages. HuggingFace models declare Python dependencies, so packagist packages are not covered.


      cvss
      9.0
      critical

      severity band, no base score published

      epss
      3.1%
      medium

      chance of exploitation in 30 days, 88th percentile of all CVEs

      xyz score
      4.0
      medium

      CyberXYZ composite out of 10

      fig. 01 — GHSA-m298-fh5c-jc66, the advisory selected below

      // 14 advisories

      GHSA-m298-fh5c-jc66

      CRITICALGitHub ratingCVE-2020-36326
      // 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 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() 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.


      Checked 2026-11-07 at 22:18 UTC. The most recent advisory here was published 2024-02-02. Updated continuously from NVD, GHSA, OSV and CNA feeds.

      Think a verdict here is wrong? Tell us — we respond within 2 business days.