Skip to main content
Mallory
← Back to News
standards-framework-updatepackage-repository-poisoningbuild-pipeline-compromisewidely-deployed-product-advisory

npm v12 disables auto-run install scripts and remote dependency paths by default

Regulatory & Policy · 13 sources · Updated 4mo ago · First seen Jun 10, 2026

npm v12 disables auto-run install scripts and remote dependency paths by default

GitHub announced that npm v12 will change default package installation behavior to curb software supply-chain attacks that abuse npm install. The release will require explicit approval before running lifecycle scripts, building native modules with node-gyp, resolving Git-based dependencies, or fetching packages from remote URLs such as HTTPS tarballs. GitHub said the changes remove several automatic code-execution and dependency-resolution paths that attackers have repeatedly used to hide malicious behavior in packages and transitive dependencies executed on developer workstations and CI runners.

The move targets techniques seen in incidents involving malicious preinstall and postinstall scripts, Git dependency abuse, and campaigns tied to packages such as eslint-config-prettier, Toptal’s Picasso packages, and the Shai-Hulud worm. npm maintainers said install-time scripts represent the ecosystem’s largest code-execution surface, though the new defaults will be breaking for some legitimate projects including Playwright, Puppeteer, Electron, and native modules that now must opt in. GitHub urged developers to upgrade to npm 11.16.0 or later ahead of the release so they can receive warnings about workflows that will fail under npm v12’s stricter defaults.

What this changes for youSee the reporting duties and controls this puts on the clock.
Get the context
Event timeline

How this story unfolded

Events from the most recent confirmed update back to the earliest known activity.

4 events · Nov 20, 2025 – Jun 10, 2026
  1. Jun 10, 20266mo ago

    GitHub advises developers to upgrade to npm 11.16.0 or later

    Alongside the npm 12 announcement, GitHub recommended that developers move to npm 11.16.0 or newer so they can receive warnings about breaking changes and prepare workflows before the new defaults arrive.

    NPM v12 to block supply-chain attacks with new security measures | brief | SC Media
  2. Jun 10, 20266mo ago

    GitHub announces npm 12 security-focused default changes

    GitHub announced that npm v12 will change default behavior to reduce software supply-chain attacks during 'npm install'. The new defaults will require explicit approval for lifecycle scripts, native module builds, Git-based dependencies, and remote URL dependency fetching.

    NPM v12 to block supply-chain attacks with new security measures | brief | SC Media
  3. Jun 10, 20266mo ago

    npm 11.10.0 introduces opt-in install security protections

    The protections that disable risky install-time behaviors were already available as opt-in features in npm 11.10.0 and later, alongside min-release-age. These features preceded the planned npm 12 default changes.

    GitHub pulls pin on npm's auto-run scripts
  4. Nov 20, 20251y ago

    npm issue reopened to propose `ignore-scripts` default

    A reopened npm/cli issue proposed setting `ignore-scripts` to `true` by default to prevent automatic execution of package installation scripts. The reporter argued this would reduce supply-chain risk by making script execution explicit and opt-in.

    Set ignore-scripts true by default · Issue #8732 · npm/cli
Linked entities

Related entities

Vulnerabilities, threat actors, malware, products, organizations, and breaches Mallory has linked to this story.

Open in app →

Affected products

1 linked
Npm

Organizations

1 linked
GitHub
Do you run this?See what this changes for your reporting obligations and which controls it puts on the clock.
Get the Regulatory Context
Mallory platform

See the full picture, correlated to your attack surface.

This page covers what’s public. Mallory adds the parts that aren’t: which of your assets are affected, which threat actors are using it right now, and what to deploy next.

Exposure mappingMap indicators from this story to your assets and identify affected systems in minutes.
Threat actor evidenceEvery observed campaign, victim, and pivot linked to actors named in this story.
Associated malwareMalware, exploits, and IOCs connected to the activity described here.
Detection signaturesYARA, Sigma, and Snort rules deployed to your SIEM as soon as they’re published.
Scheduled alertsGet matching new stories delivered to your team as they break, not the next morning.
AI threadsAsk questions about this story and take action on the answers.