Skip to content

[BUG] npm@latest still bundles vulnerable tar@7.5.1 (GHSA-29xp-372q-xqph) #8715

Closed

Description

@iam-idi

Is there an existing issue for this?

  • I have searched the existing issues

This issue exists in the latest npm version

  • I am using the latest npm

Current Behavior

Running npm audit flags a moderate severity vulnerability (GHSA-29xp-372q-xqph) due to tar@7.5.1 bundled within npm@11.6.2.
The issue stems from node-tar having a race condition that could lead to uninitialized memory exposure.
Even though tar@1.57.2 has been released with a fix, the latest npm version (11.6.2) still depends on the vulnerable version (tar@1.57.1).
This causes CI/CD audit pipelines to fail despite using the latest npm release.

Expected Behavior

The latest npm release (11.6.2) should depend on a non-vulnerable version of tar.
Running npm audit should return zero vulnerabilities when using the most up to date npm version, ensuring that security audits and CI/CD pipelines complete successfully without false vulnerability flags.

Steps To Reproduce

  1. In this environment:
  • Node.js version: <=23.5.0
  • npm version: <=11.6.2
  1. With this configuration:

    Project uses npm’s default audit behavior in a CI/CD pipeline.
    No custom overrides or local tar installations.

  2. Run:
    npm audit

  3. Error:

# npm audit report

tar  7.5.1
Severity: moderate
node-tar has a race condition leading to uninitialized memory exposure - https://github.com/advisories/GHSA-29xp-372q-xqph
fix available via `npm audit fix`
node_modules/npm/node_modules/tar
  npm  7.21.0 - 8.5.4 || >=11.6.1
  Depends on vulnerable versions of tar
  node_modules/npm

2 moderate severity vulnerabilities

Environment

npm: 11.6.2
Node.js: 22.14.0
OS Name: macOS 13.7.1 (Ventura)
System Model Name: MacBook Pro 2017
npm config ls: ; "user" config from /Users//.npmrc

node bin location = /usr/local/bin/node
; node version = v22.14.0
; npm local prefix = /Users/mac/Desktop/batman  /code/company/main-api
; npm version = 11.6.2
; cwd = /Users/mac/Desktop/batman  /code/company/main-api
; HOME = /Users/mac

Activity

  1. added
    Bugthing that needs fixing
    Needs Triageneeds review for next steps
    on Oct 31, 2025
  2. changed the title [-][BUG] npm@latest still bundles vulnerable tar@1.57.1 (GHSA-29xp-372q-xqph)[/-] [+][BUG] npm@latest still bundles vulnerable tar@7.5.1 (GHSA-29xp-372q-xqph)[/+] on Oct 31, 2025
  3. MikeMcC399 commented on Nov 6, 2025

    @MikeMcC399
    Contributor

    This would be resolved by #8723

  4. huakaibird commented on Nov 10, 2025

    @huakaibird

    When this could be done?

  5. wraithgar commented on Nov 17, 2025

    @wraithgar
    Contributor

    npm itself is not affected by this, it never uses the synchronous version of node-tar. A new version of npm should be released this week w/ the latest node-tar.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Bugthing that needs fixingNeeds Triageneeds review for next steps

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions