CVE-2019-16775Unauthorized File Access in npm CLI before before version 6.13.3
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.
What to do
Fixed builds are available from AlmaLinux, Debian, Red Hat, Rocky Linux, npm: see the table below for the fixed version per release.
Ubuntu has not shipped a fix for every release yet.
Is your server affected? One read-only command checks every installed package against this CVE and all others, using each vendor's fixed versions. Get started or get a free API key.
curl -sS "https://api.cvefocus.com/v1/check?format=text" -H "Authorization: Bearer $CVEFOCUS_KEY" \ -H "Content-Type: text/plain" --data-binary @inventory.txt
Vendor status at a glance
Status by vendor and release
From each vendor's own security data and VEX statements. "Fixed" means a fixed build is published for that release.
| Release | Package | Status | Fixed version | Advisory |
|---|---|---|---|---|
| Ubuntu 26.10 | npm | Fix pending | UBUNTU-CVE-2019-16775 | |
| Ubuntu 26.04 | npm | Under investigation | UBUNTU-CVE-2019-16775 | |
| Ubuntu 25.10 | npm | Will not fix Ubuntu decided not to fix this in this release | UBUNTU-CVE-2019-16775 | |
| Ubuntu 24.04 | npm | Under investigation | UBUNTU-CVE-2019-16775 | |
| Ubuntu 22.04 | npm | Under investigation | UBUNTU-CVE-2019-16775 | |
| Ubuntu 20.04 | npm | Will not fix Ubuntu decided not to fix this in this release | UBUNTU-CVE-2019-16775 | |
| Ubuntu 18.04 | npm | Fix pending | UBUNTU-CVE-2019-16775 | |
| Ubuntu 16.04 | npm | Will not fix Ubuntu decided not to fix this in this release | UBUNTU-CVE-2019-16775 | |
| Ubuntu 14.04 | npm | Will not fix Ubuntu decided not to fix this in this release | UBUNTU-CVE-2019-16775 | |
| Debian 14 | npm | Fixed | 6.13.4+ds-2 | DEBIAN-CVE-2019-16775 |
| Debian 13 | npm | Fixed | 6.13.4+ds-2 | DEBIAN-CVE-2019-16775 |
| Debian 12 | npm | Fixed | 6.13.4+ds-2 | DEBIAN-CVE-2019-16775 |
| Red Hat Enterprise Linux 8 | nodejs | Fixed | 1:12.14.1-1.module+el8.1.0+5466+30f75629 | RHSA-2020:0579 |
| Red Hat Enterprise Linux 8 | nodejs-devel | Fixed | 1:12.14.1-1.module+el8.1.0+5466+30f75629 | RHSA-2020:0579 |
| Red Hat Enterprise Linux 8 | nodejs-docs | Fixed | 1:10.19.0-1.module+el8.1.0+5726+6ed65f8c | RHEA-2020:0330 |
| Red Hat Enterprise Linux 8 | nodejs-nodemon | Fixed | 0:1.18.3-1.module+el8.1.0+3369+37ae6a45 | RHSA-2020:0579 |
| Red Hat Enterprise Linux 8 | nodejs-packaging | Fixed | 0:17-3.module+el8+2873+aa7dfd9a | RHEA-2020:0330 |
| Red Hat Enterprise Linux 8 | npm | Fixed | 1:6.13.4-1.12.14.1.1.module+el8.1.0+5466+30f75629 | RHSA-2020:0579 |
| AlmaLinux 8 | nodejs-nodemon | Fixed | 1.18.3-1.module_el8.3.0+2023+d2377ea3 | ALSA-2020:0579 |
| AlmaLinux 8 | nodejs-packaging | Fixed | 17-3.module_el8.3.0+2023+d2377ea3 | ALSA-2020:0579 |
| Rocky Linux 8 | nodejs-nodemon | Fixed | 0:1.18.3-1.module+el8.3.0+101+f84c7154 | RLSA-2020:0579 |
| Rocky Linux 8 | nodejs-packaging | Fixed | 0:17-3.module+el8.3.0+101+f84c7154 | RLSA-2020:0579 |
| npm library | npm | Fixed | 6.13.3 | GHSA-m6cx-g6qm-p2cx |
What the vendor says
As published in the CVE record by GitHub_M, the CVE's assigner (usually the vendor). Check the vendor's advisory before acting.
- npm cli: affected: < 6.13.3 to before 6.13.3; fixed in
6.13.3
Vendor advisories:
- http://lists.opensuse.org/opensuse-security-announce/2020-01/msg00027.html (vendor-advisory)
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/… (vendor-advisory)
- https://access.redhat.com/errata/RHEA-2020:0330 (vendor-advisory)
- https://access.redhat.com/errata/RHSA-2020:0573 (vendor-advisory)
- https://access.redhat.com/errata/RHSA-2020:0579 (vendor-advisory)
- https://access.redhat.com/errata/RHSA-2020:0597 (vendor-advisory)
References
- http://lists.opensuse.org/opensuse-security-announce/2020-01/msg00027.html
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/Z36UKPO5F3PQ3Q2POMF5LEKXWAH5RUFP/
- https://access.redhat.com/errata/RHEA-2020:0330
- https://access.redhat.com/errata/RHSA-2020:0573
- https://access.redhat.com/errata/RHSA-2020:0579
- https://access.redhat.com/errata/RHSA-2020:0597
- https://access.redhat.com/errata/RHSA-2020:0602
- https://www.oracle.com/security-alerts/cpujan2020.html
- https://www.oracle.com/security-alerts/cpuoct2021.html
- https://github.com/npm/cli/security/advisories/GHSA-m6cx-g6qm-p2cx
- https://blog.npmjs.org/post/189618601100/binary-planting-with-the-npm-cli
About this page
Compiled by CVEfocus from the CVE List, the security data and VEX statements of Ubuntu, Debian, Red Hat, AlmaLinux, Rocky Linux and Microsoft, CISA's Known Exploited Vulnerabilities catalog and FIRST EPSS, refreshed several times a day (data status). Information only; see the disclaimer. Official record: cve.org · NVD.