ChainDrop Inside a Self-Propagating npm Worm - #338
Open
carlospolop wants to merge 1 commit into
Open
Conversation
Collaborator
Author
🔗 Additional ContextOriginal Blog Post: https://unit42.paloaltonetworks.com/chaindrop-npm-worm-analysis Content Categories: Based on the analysis, this content was categorized under "Pentesting CI/CD > Github Security > Abusing Github Actions > npm Supply Chain Abuse; add subsections for npm lifecycle-hook worms, runner process-memory secret theft, OIDC trusted-publishing abuse, malicious-workflow provenance, and credential-driven package propagation". Repository Maintenance:
Review Notes:
Bot Version: HackTricks News Bot v1.0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🤖 Automated Content Update
This PR was automatically generated by the HackTricks News Bot based on a technical blog post.
📝 Source Information
🎯 Content Summary
Overview and severity
ChainDrop is a critical, self-propagating npm supply-chain worm from the Shai-Hulud code lineage. It infected over 400 packages collectively downloaded hundreds of millions of times per week, including malicious versions of
keyvandcacheable-request. Unit 42 detected execution in 10 distinct environments and identified 453 public GitHub repositories across five candidate victim accounts that matched the worm's exfiltration pattern; the ...🔧 Technical Details
Lifecycle-hook supply-chain execution: An npm package can retain all legitimate functionality while adding a small dropper, an obfuscated payload and
"preinstall": "node setup.mjs". npm executes the dropper automatically during installation. The dropper can download or reuse a legitimate portable runtime such as Bun, detach the malicious process outside CI and set an environment marker such as_NODE_RUNTIME_INIT=1to prevent recursive relaunch.Environment-aware execution: Malware can alter execution depending on whether it detects CI. Detaching on workstations hides execution and lets installation complete normally, while inline execution in CI inherits access to workflow credentials but may expose debugging output in job logs. Locale checks can selectively exclude systems in chosen regions.
CI process-memory credential theft: Malware on a Linux runner can locate a privilege...
🤖 Agent Actions
Updated:
src/pentesting-ci-cd/github-security/abusing-github-actions/gh-actions-npm-supply-chain-abuse.mdAdded concise, cited coverage for:
/proc/<pid>/mapsand/proc/<pid>/mem${{ toJSON(secrets) }}Also fixed that page’s
## Referencessection to numbered format and added inline citation superscripts.This PR was automatically created by the HackTricks Feed Bot. Please review the changes carefully before merging.