Unauthorized File Access in npm CLI before before version 6.13.3 (npm cli)

CVE-2019-16775
HIGH 7.7

At a glance

Source
NVD
EPSS
EPSS 3.33 % · percentile 89 ()
State
PUBLISHED
Published
Updated
Assigner
GitHub_M
NVD status
Modified

Description

Versions of the npm CLI prior to 6.13.3 are vulnerable to an Arbitrary File Write. It is possible for packages to create symlinks to files outside of thenode_modules folder through the bin field upon installation. A properly constructed entry in the package.json bin field would allow a package publisher to create a symlink pointing to arbitrary files on a user's system when the package is installed. This behavior is still possible through install scripts. This vulnerability bypasses a user using the --ignore-scripts install option.

Weaknesses (CWE)

  • CWE-61 — UNIX Symbolic Link (Symlink) Following
  • CWE-59 — Improper Link Resolution Before File Access

References

Scores

VersionScoreVectorScored by
CVSS 3.1HIGH 7.7CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:C/C:H/I:H/A:NGitHub_M
CVSS 3.1HIGH 7.7CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:C/C:H/I:H/A:NNVD · security-advisories@github.com (Secondary)
CVSS 3.1MEDIUM 6.5CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:NNVD · nvd@nist.gov (Primary)
CVSS 2.0MEDIUM 4.0AV:N/AC:L/Au:S/C:N/I:P/A:NNVD · nvd@nist.gov (Primary)

Advisories

European references

CERT-FR advisories

Affected configurations (NVD CPE)

Affected products

ProductVersions
npm · cliaffected < 6.13.3 < 6.13.3

Sources

SourceLicence
CVE List (CVEProject cvelistV5)CVE Program Terms of Use
EPSS (FIRST.org)FIRST — attribution requested
ENISA EUVDENISA — reproduction authorised, source acknowledged
CERT-FR (ANSSI)Licence Ouverte / Etalab 2.0
NVD (NIST) via fkie-cad/nvd-json-data-feedsPublic domain — this product uses data from the NVD API but is not endorsed or certified by the NVD