# CVE-2022-29244: npm pack root-level ignore file bypass in workspaces

Source: https://junglewise.ai/threats/cve-2022-29244-npm-pack-root-level-ignore-file-bypass-in-workspaces  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2022-06-02. Updated: 2026-09-25  
License: CC BY 4.0 with a link back

CVE-2022-29244 · Severity: low · CVSS 3.1 · Published 2022-06-02

npm is a package manager that handles code distribution. When developers publish packages to the npm registry using workspaces (a feature for managing multiple packages in a single repository), npm incorrectly includes files that should have been excluded based on .gitignore and .npmignore rules. This could cause sensitive files, configuration data, or private information to be accidentally published to the public registry.

Technologies: [npm (npm)](https://junglewise.ai/threats/technologies/npm). Vendors: [npm](https://junglewise.ai/threats/vendors/npm).

## Quick answers

**Is CVE-2022-29244 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2022-29244 being exploited in the wild.

**How severe is CVE-2022-29244?** Low severity, with a CVSS score of 3.1, published 2 June 2022.

**Which products and versions are affected?** npm (npm) >=7.9.0, <8.11.0.

**Is there a fix for CVE-2022-29244?** A patch was published on 2022-06-02: npm v8.11.0 released Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is CVE-2022-29244 attacked?** It is attacked over the network, in a software library.

**Am I affected by CVE-2022-29244?** Check whether you run npm (npm) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## Technical details

The vulnerability is a file inclusion bypass (CWE-200) in npm's packing and publishing logic. When npm pack or npm publish is run with workspace flags (--workspaces or --workspace=<name>) on versions 7.9.0 to 8.10.x, root-level .gitignore and .npmignore exclusion directives are ignored, causing unintended files to be bundled into packages. The attack vector is local (requires running the affected npm command), but the impact is information disclosure through published packages in the npm registry. Patch: upgrade to npm v8.11.0 or later (included in Node.js v16.15.1, v17.19.1, and v18.3.0).

## Affected products

- npm npm >=7.9.0, <8.11.0

## Identifiers

- CVE-2022-29244
- GHSA-hj9c-8jmm-8c52

## Timeline

- 2022-06-02: disclosed
- 2022-06-02: patched: npm v8.11.0 released

## References

- [https://github.com/npm/cli/security/advisories/GHSA-hj9c-8jmm-8c52](https://github.com/npm/cli/security/advisories/GHSA-hj9c-8jmm-8c52)

## Related threats

- [npm cli local privilege escalation via uncontrolled module search path](https://junglewise.ai/threats/cve-2026-0775-npm-cli-local-privilege-escalation-via-uncontrolled-module-search)
- [npm incorrect permission assignment in mkdir](https://junglewise.ai/threats/cve-2018-7408-npm-incorrect-permission-assignment-in-mkdir)
- [npm Arborist symlink following on case-insensitive filesystems](https://junglewise.ai/threats/cve-2021-39134-npm-arborist-symlink-following-on-case-insensitive-filesystems)
- [npm public path traversal via symlink navigation](https://junglewise.ai/threats/npm-public-path-traversal-via-symlink-navigation-dd9ade29)
- [npm content denial of service in HTTP header parser](https://junglewise.ai/threats/npm-content-denial-of-service-in-http-header-parser-4db9bd00)
