All Topics
All Topics
Technology
Technology
Design
Design
Programming
Programming
Science
Science
News
News
Gaming
Gaming
Entertainment
Entertainment
Business
Business
Finance
Finance
Sports
Sports
Health
Health
Food
Food
Travel
Travel
Art
Art
Music
Music
Books
Books
Education
Education
Politics
Politics
Personal
Personal
No algorithm. No AI slop. No ads. Just RSS. Pro-human. Indie writers. Real journalism. Open web. Chronological. Hand toasted.

GitHub changes npm defaults to disable automatic script execution on install, closing major security vector

By

Tim Anderson

12h ago· 3 min readenNews

Summary

GitHub is changing npm's default behavior so that the install command no longer automatically runs lifecycle scripts, closing a major security vulnerability that has been exploited by malicious packages like the Shai-Hulud worm. This feature, which allowed arbitrary code execution from any compromised dependency in a developer's dependency tree, has been described as the largest code-execution surface in the npm ecosystem. The change aims to significantly improve security for developers and CI environments.

Key quotes

· 2 pulled
Install-time lifecycle scripts are the single largest code-execution surface in the npm ecosystem.
Every npm install runs scripts from every transitive dependency, so a single compromised package anywhere in your tree can execute arbitrary code on a developer machine or CI.
Snippet from the RSS feed
Shai-Hulud worm exploited exactly this. Better late than never, says everyone except the malware authors

You might also wanna read