Threat reportMalwareTL-2026-7138
Live malware in Shai-Hulud detector test files (G DATA: Testing with live malware)
G DATA reported that test files shipped with a detector for the Shai-Hulud npm worm exhibited real malicious behavior, including scripts that delete user directories and upload data to real threat actors. Users browsing the program folder could execute them by accident. First disclosed .
Key facts
| Identifiers | TL-2026-7138 |
|---|---|
| Severity | LOW |
| First disclosed | |
| Affected products | Unnamed open-source project Shai-Hulud npm worm detector (repository not named by G DATA) |
| Malware | Shai-Hulud |
| Tools | TruffleHog - S9009 |
| MITRE ATT&CK techniques | T1027 Obfuscated Files or Information, T1059.001 PowerShell, T1059.004 Unix Shell, T1195.002 Compromise Software Supply Chain, T1204.002 Malicious File, T1485 Data Destruction, T1552.001 Credentials In Files, T1567 Exfiltration Over Web Service |
| Motivation | UNKNOWN |
| Target sectors | technology, software development |
| Target regions | Global |
| Detection rules | 9 (1 shown free) |
| Sources | 6 cited sources |
Detection coverage
As of 2026-12-01, Threadlinqs Intelligence publishes 9 detection rule(s) for TL-2026-7138 across Splunk SPL, Microsoft KQL and Sigma, covering 20 indicator(s) of compromise. The whole corpus is readable without an account. Every threat comes with one complete detection in Splunk SPL, Microsoft KQL and Sigma, free for everyone; a free account adds daily TL Creds to unlock the rest. Paid plans add a larger daily allowance, correlation and the MCP server. Threadlinqs MCP server · View plans.
Free detection: Shai-Hulud 2.0 Loader / Payload / TruffleHog Execution via Node Runtime
Behaviour-first detection of the Shai-Hulud npm worm (TL-2026-7138 context, Unit 42 / CISA): process creation referencing the Shai-Hulud 2.0 pre-install loader setup_bun.js or the obfuscated bun_environment.js payload, or TruffleHog launched by node, bun or npm to harvest secrets. Covers supply-chain execution of trojanized npm packages.
- Languages: Splunk SPL, Microsoft KQL, Sigma
- ATT&CK: T1195.002, T1204.002, T1027
- Data sources: sysmon, splunk:XmlWinEventLog:Microsoft-Windows-Sysmon/Operational, DeviceProcessEvents
- Severity: high
- Confidence: high
Splunk SPL
index=sysmon sourcetype="XmlWinEventLog:Microsoft-Windows-Sysmon/Operational" EventCode=1 earliest=-24h
(CommandLine="*setup_bun.js*" OR CommandLine="*bun_environment.js*" OR ParentCommandLine="*setup_bun.js*" OR ParentCommandLine="*bun_environment.js*"
OR (Image="*trufflehog.exe" AND (ParentImage="*node.exe" OR ParentImage="*bun.exe" OR ParentImage="*npm.cmd")))
| eval indicator=case(match(CommandLine,"(?i)setup_bun[.]js") OR match(ParentCommandLine,"(?i)setup_bun[.]js"),"shai-hulud-2.0-loader-setup_bun.js", match(CommandLine,"(?i)bun_environment[.]js") OR match(ParentCommandLine,"(?i)bun_environment[.]js"),"shai-hulud-2.0-payload-bun_environment.js", match(Image,"(?i)trufflehog"),"trufflehog-spawned-by-node-runtime", true(),"parent-chain-match")
| stats count min(_time) as first_seen max(_time) as last_seen values(CommandLine) as command_lines values(ParentImage) as parent_images values(ParentCommandLine) as parent_command_lines by host User indicator
| convert ctime(first_seen) ctime(last_seen)Microsoft KQL
DeviceProcessEvents
| where Timestamp > ago(24h)
| where ProcessCommandLine has_any ("setup_bun.js", "bun_environment.js")
or InitiatingProcessCommandLine has_any ("setup_bun.js", "bun_environment.js")
or (FileName in~ ("trufflehog.exe", "trufflehog") and InitiatingProcessFileName in~ ("node.exe", "node", "bun.exe", "bun", "npm.cmd", "npm"))
| extend Indicator = case(
ProcessCommandLine has "setup_bun.js" or InitiatingProcessCommandLine has "setup_bun.js", "ShaiHulud2-Loader-setup_bun.js",
ProcessCommandLine has "bun_environment.js" or InitiatingProcessCommandLine has "bun_environment.js", "ShaiHulud2-Payload-bun_environment.js",
"TruffleHog-from-node-runtime")
| project Timestamp, DeviceName, AccountName, Indicator, FileName, ProcessCommandLine, InitiatingProcessFileName, InitiatingProcessCommandLine, SHA256
| order by Timestamp descSigma
title: Shai-Hulud 2.0 Loader, Payload or TruffleHog Execution via Node Runtime
id: 7d1c0a52-3b6e-4f1a-9c58-2e4a8b7d6c11
status: experimental
description: Detects execution of the Shai-Hulud 2.0 setup_bun.js loader or bun_environment.js payload, or TruffleHog spawned by a Node, Bun or npm parent (credential harvesting by the npm worm).
references:
- https://blog.gdatasoftware.com/2026/02/38370-malware-in-test-files
- https://www.cisa.gov/news-events/alerts/2025/09/23/widespread-supply-chain-compromise-impacting-npm-ecosystem
- https://unit42.paloaltonetworks.com/npm-supply-chain-attack/
author: Threadlinqs Team
date: 2026/12/01
tags:
- attack.initial-access
- attack.t1195.002
- attack.execution
- attack.t1204.002
- attack.defense-evasion
- attack.t1027
logsource:
category: process_creation
product: windows
detection:
selection_loader:
CommandLine|contains:
- 'setup_bun.js'
- 'bun_environment.js'
selection_parent:
ParentCommandLine|contains:
- 'setup_bun.js'
- 'bun_environment.js'
selection_trufflehog:
Image|endswith: '\trufflehog.exe'
ParentImage|endswith:
- '\node.exe'
- '\bun.exe'
- '\npm.cmd'
condition: 1 of selection_*
falsepositives:
- Security researchers analysing Shai-Hulud samples in an instrumented lab
- Developers legitimately running TruffleHog from an npm script in CI
level: high
Known false positives:
- Security researchers detonating Shai-Hulud samples in an instrumented lab
- Developers or CI jobs that legitimately run TruffleHog from an npm script
- Detector test fixtures that merely contain the file names as strings
Tuning notes: Scope to developer workstations and CI runners. Allow-list sanctioned TruffleHog CI pipelines by host and parent command line, using a NOT clause before the stats command. Extend the file-name list as new Shai-Hulud variants are published.
- Shai-Hulud Payload / Loader File and Hash Match · unlock with TL Creds
- npm [indicator] Token File Read or Staged via Command Line · unlock with TL Creds
- Script Runtime HTTP Egress to [indicator] · unlock with TL Creds
- Detector Test File Executed - SIMULATED MALICIOUS SCRIPT PowerShell Header · unlock with TL Creds
- Destructive Home Directory Deletion (Shai-Hulud 2.0 Fallback Class) · unlock with TL Creds
- Shai-Hulud 2.0 Self-Hosted Runner Registration (SHA1HULUD) · unlock with TL Creds
- PowerShell [indicator] Credential Access with Recursive Deletion · unlock with TL Creds
- [indicator] DNS Lookup from Script Runtime (Shai-Hulud Exfiltration) · unlock with TL Creds
Indicators of compromise
As of 2026-12-01, Threadlinqs Intelligence tracks 20 indicators of compromise for TL-2026-7138.
Sample indicators (3 of 20)
- Domain:
webhook[.]site - File hash:
46faab8ab153fae6e80e7cca38eab363075bb524edd79e42269217a083628f09 - File hash:
b74caeaa75e077c99f7d44f46daaf9796a3be43ecf24f2a1fd381844669da777
Defanged, TLP:CLEAR. Full set of 20 indicators: unlock with TL Creds.
Technical analysis
The maintainer neutralized the files on 2026-02-17.
On 2026-02-16 G DATA Software published a blog post, 'Testing with live malware: Good Intentions, Problematic Execution', after a customer submitted test files from an open-source detector for the Shai-Hulud npm worm and described them as false detections. G DATA analyzed the files and concluded they were not false positives. The files contained scripts that, if executed, would delete user directories and upload data to real threat actors. One PowerShell test file carried the header '# SIMULATED MALICIOUS SCRIPT - PowerShell destructive patterns'. Its comments describe the actions as simulated, but the commands would really run. Per the post's image caption, the file reads credentials from environment variables and the .npmrc file and includes recursive file deletion.
G DATA stated it cannot assume malicious intent by the maintainer. The detector checks files for specific patterns (such as certain internet addresses), and the test files are not run during normal use; they exist to be detected by the scanner. The risk is that a user browsing the program folder could double-click a file and run it, causing data loss or credential/data exfiltration. G DATA's recommendations: add test cases to .gitignore and do not distribute them, run tests involving live malware only in a sandbox, and review AI-generated results manually before release. Update 2026-02-17: the project maintainer neutralized the test files, so there is no longer a risk of accidentally downloading, executing or detecting malware through them.
Evidence limits: the G DATA post does not name the detector, its maintainer or repository, and gives no hashes, domains, URLs or file names beyond the PowerShell header. This record does not attribute the incident to any specific repository. The public Cobenian/shai-hulud-detect project surfaced in search results, but its README tells contributors not to include actual malware in fixtures, and nothing retrieved confirms it is the detector G DATA examined. The IOCs listed are indicators of the Shai-Hulud worm itself (from Unit 42 and CISA) for context and hunting; they are not indicators extracted from the test files.
Background on the worm the detector targets: Shai-Hulud is a self-replicating npm worm first seen in September 2025 (500+ packages per CISA). It steals .npmrc npm tokens, GitHub PATs and AWS/GCP/Azure keys, exfiltrates to an attacker endpoint (webhook.site) and a public GitHub repository named 'Shai-Hulud', then uses the stolen npm token to publish trojanized versions of other packages. Shai-Hulud 2.0 (November 2025) moved execution to pre-install and added a destructive fallback that overwrites and deletes writable files in the user's home directory. This is the behavior class the test files reproduced.
MITRE ATT&CK techniques by tactic:
Defense Evasion
T1027 Obfuscated Files or Information
Execution
T1059.001 PowerShell; T1059.004 Unix Shell; T1204.002 Malicious File
Initial Access
T1195.002 Compromise Software Supply Chain
Impact
Credential Access
T1552.001 Credentials In Files
Exfiltration
Remediation
Patches
- Maintainer neutralized the test files on 2026-02-17 (per G DATA update)
Immediate actions
- Do not open or execute files inside Shai-Hulud detector program folders or test-case directories outside a sandbox
- Update to a detector release in which the maintainer neutralized the test files (fix announced 2026-02-17)
- Hunt for the Shai-Hulud worm indicators listed in this record; rotate npm tokens, GitHub PATs and cloud keys if exposure is suspected
Workarounds
- Delete or quarantine the test-case folder of the detector if an older copy is present
- Block outbound connections to webhook.site from developer and CI systems (CISA guidance for Shai-Hulud)
Longer-term hardening
- Keep test fixtures inert: use synthetic strings and files rather than live malware
- Exclude live-malware test cases from distribution and add them to .gitignore
- Run any live-malware testing only in an isolated sandbox
- Manually review AI-generated code and test cases before release
Affected and fixed versions
- Unnamed open-source project — Shai-Hulud npm worm detector (repository not named by G DATA)
Vulnerable versions: Releases shipping live-malware test files before 2026-02-17
Fixed in: Releases after the maintainer neutralized the test files (2026-02-17)
Timeline
- CISA later advised pinning npm dependencies to releases published before this date, marking the start of the original Shai-Hulud compromise window
- CISA published an alert on the widespread npm supply chain compromise by the self-replicating Shai-Hulud worm (500+ packages)
- Unit 42 update covering Shai-Hulud 2.0: pre-install execution, destructive home-directory fallback, 25,000+ malicious GitHub repositories
- G DATA published its blog post after a customer submitted Shai-Hulud detector test files reported as false detections; analysis showed real destructive and upload behavior
- The public Cobenian/shai-hulud-detect README lists a 'SANDWORM_MODE workflow poisoning' wave dated 2026-02-17 (separate from the test-file issue)
- G DATA update: the project maintainer neutralized the test files, removing the risk of accidental execution
Sources cited
- CISA: Widespread Supply Chain Compromise Impacting npm Ecosystem CISA · Government advisory · 2025-09-23
- Palo Alto Networks Unit 42: npm Supply Chain Attack (Shai-Hulud) Unit 42 · Research · 2025-11-25
- Checkmarx: Inside Shai-Hulud's Maw - how the npm worm exploits and propagates checkmarx.com · Research
- GitLab: GitLab discovers widespread npm supply chain attack GitLab · Vendor report · 2025-11-24
- Cobenian/shai-hulud-detect (public Shai-Hulud detector; not confirmed as the tool in G DATA's post) GitHub · Code repository
- Testing with live malware: Good Intentions, Problematic Execution (G DATA) blog.gdatasoftware.com · Blog · 2026-02-16
Previous and next in malware
AI-drafted from 6 cited sources; published ; last updated —.