Skip to content

OS Command injection in npm-lockfile

Critical severity GitHub Reviewed Published Mar 4, 2022 to the GitHub Advisory Database • Updated Feb 3, 2023

Package

npm npm-lockfile (npm)

Affected versions

>= 2.0.3, < 2.0.5

Patched versions

2.0.5

Description

npm-lockfile safely generates an npm lockfile and output it to the filename of your choice. npm-lockfile before 2.0.4 does not santize unsafe external input and invoke sensitive command execution API with the input, causing command injection vulnerability. A fix was released in version 2.0.5.

References

Published by the National Vulnerability Database Mar 3, 2022
Published to the GitHub Advisory Database Mar 4, 2022
Reviewed Mar 4, 2022
Last updated Feb 3, 2023

Severity

Critical
9.8
/ 10

CVSS base metrics

Attack vector
Network
Attack complexity
Low
Privileges required
None
User interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Weaknesses

CVE ID

CVE-2022-0841

GHSA ID

GHSA-cr6m-62pq-hmqh

Source code

Credits

Checking history
See something to contribute? Suggest improvements for this vulnerability.