
Mini Shai-Hulud Is Back: npm Worm Hits over 160 Packages, including Mistral and Tanstack
Aikido details a new wave of the Mini Shai-Hulud npm worm that has compromised 373 malicious package-version entries across 169 package names, including TanStack, Mistral AI, UiPath, and Squawk packages. Unlike the earlier SAP-focused wave (setup.mjs/execution.js), this version drops a root-level router_init.js and adds a malicious GitHub-hosted optionalDependency (@tanstack/setup) whose prepare script silently runs a Bun-based credential stealer targeting npm/GitHub tokens, AWS/Kubernetes/Vault secrets, and GitHub Actions OIDC tokens, then abuses trusted publishing to self-propagate by minting fresh npm publish tokens and pushing new compromised releases. The post includes full affected-package/version lists, file hashes, network IOCs, and remediation/rotation guidance.
What it is
"Mini Shai-Hulud," an npm supply-chain worm tracked by Aikido's Malware Team — 373 malicious package-version entries across 169 package names. This is the follow-up to their April SAP-targeted wave. The summary names the headline packages; the concrete cluster sizes are: @squawk (87 versions), @tanstack (83), @uipath (66), unscoped packages (39), @tallyui (30), @beproduct (18).
How it works
The compromised TanStack packages ship an obfuscated router_init.js at package root and declare an optional dependency pointing at a GitHub-hosted package:
"optionalDependencies": {
"@tanstack/setup": "github:tanstack/router#79ac49eedf774dd4b0cfa308722bc463cfe5885c"
}That Git dependency carries a prepare script — bun run tanstack_runner.js && exit 1. npm runs lifecycle scripts for Git dependencies during install, so the payload executes even though nothing was "installed." Because the dependency is optional, the trailing exit 1 makes install fail after the code has run, so the failure looks like a benign optional-dep hiccup rather than a compromise. (Note: this differs from the SAP wave, which used a preinstall hook running setup.mjs → execution.js.)
What to do
The page's core detection step is grepping lockfiles and package caches for affected namespaces/packages:
@squawk/
@tanstack/
@uipath/
@tallyui/
@beproduct/nestjs-auth
@mistralai/
@draftauth/
@draftlab/
@taskflow-corp/cli
@tolka/cli
@ml-toolkit-ts/
@mesadev/
@dirigible-ai/sdk
@supersurkhet/Plus unscoped names including safe-action, ts-dna, cross-stitch, cmux-agent-mcp, agentwork-cli, git-branch-selector, wot-api. The page notes the full list keeps moving and is appended to the blog.
The payload targets CI/CD and dev environments, hunting for: GitHub tokens, npm tokens, GitHub Actions OIDC tokens, AWS credentials + instance metadata, Kubernetes service-account files, HashiCorp Vault tokens and local Vault endpoints, env vars, and local filesystem secrets — so rotate any of these reachable from an affected build.
Caveats
The most important point for defenders: provenance is not a safety signal here. Trusted publishing lets a GitHub Actions workflow mint a short-lived npm token via OIDC. When attacker code runs inside that workflow, it uses the workflow's own OIDC permissions to publish — no long-lived token theft needed — and the result still carries valid provenance from the expected workflow. Provenance tells you where a package was built, not that the build was safe. This is the self-propagation engine: stolen access → repack → bump → republish.
flowchart TD
A[Optional GitHub dep] --> B[prepare: bun run + exit 1]
B --> C[Payload runs, install marked failed]
C --> D[Steal npm/GitHub/OIDC/AWS/K8s/Vault]
D --> E{Can victim publish?}
E -->|OIDC in workflow| F[Mint token, repack, republish]
F --> A
E -->|No access| G[Exfil only]Technologies named here
- Aikido
- @tanstack/history
- Aikido Endpoint Protection
- @tanstack/react-router
- Aikido Safe Chain
- @tanstack/router-core
- Bun
- @tanstack/router-utils
- @tanstack/router-plugin
- @tanstack/virtual-file-routes
- @tanstack/router-generator
- @tanstack/start-server-core
- @tanstack/start-client-core
- @tanstack/start-storage-context
- @tanstack/start-plugin-core
- @tanstack/react-start-server
- @tanstack/react-start-client
- @tanstack/start-fn-stubs
- @tanstack/react-start
- @tanstack/react-start-rsc
- @mistralai/mistralai
- @tanstack/react-router-devtools
- @tanstack/router-devtools-core
- @tanstack/router-devtools
- @tanstack/router-ssr-query-core
- @tanstack/react-router-ssr-query
- @tanstack/router-cli
- @tanstack/zod-adapter
- @tanstack/eslint-plugin-router
- @tanstack/router-vite-plugin
- @tanstack/nitro-v2-vite-plugin
- @mistralai/mistralai-gcp
- @tanstack/solid-router
- @tanstack/solid-start
- @tanstack/solid-start-client
- @tanstack/solid-start-server
- @tanstack/solid-router-devtools
- @tanstack/start-static-server-functions
- @tanstack/vue-router
- @uipath/apollo-react
- @tanstack/solid-router-ssr-query
- safe-action
- @tanstack/valibot-adapter
- @tanstack/vue-start
- @uipath/apollo-wind
- @uipath/cli
- @tanstack/vue-start-server
- @squawk/types
- @uipath/rpa-tool
- @squawk/mcp
- @tanstack/vue-start-client
- @squawk/weather
- @squawk/airspace
- @squawk/icao-registry-data
- @tanstack/arktype-adapter
- @squawk/flightplan
- @squawk/airports
- @mesadev/sdk
- @squawk/geo
- @mesadev/rest
- @squawk/procedure-data
- @squawk/navaid-data
- @squawk/fix-data
- @squawk/navaids
- @squawk/fixes
- @squawk/airport-data
- @squawk/airway-data
- @squawk/units
- @squawk/procedures
- @squawk/airways
- @squawk/icao-registry
- @uipath/apollo-core
- @squawk/notams
- @uipath/filesystem
- @uipath/solutionpackager-tool-core
- @squawk/flight-math
- @squawk/airspace-data
- @mistralai/mistralai-azure
- @uipath/solution-tool
- @tanstack/eslint-plugin-start
- @uipath/maestro-tool
- @uipath/codedapp-tool
- @uipath/agent-tool
- @draftlab/auth
- @uipath/orchestrator-tool
- @uipath/integrationservice-tool
- @taskflow-corp/cli
- @tanstack/vue-router-ssr-query
- @uipath/rpa-legacy-tool
- @uipath/vertical-solutions-tool
- @uipath/flow-tool
- @uipath/codedagent-tool
- @uipath/common
- @uipath/resource-tool
- @uipath/auth
- @uipath/docsai-tool
- @uipath/case-tool
- @uipath/api-workflow-tool
- @tanstack/vue-router-devtools
- @uipath/test-manager-tool
- @uipath/robot
- @uipath/traces-tool
- @uipath/agent-sdk
- @uipath/integrationservice-sdk
- @uipath/maestro-sdk
- @uipath/data-fabric-tool
- @mesadev/saguaro
- @uipath/tasks-tool
- @uipath/insights-tool
- @uipath/insights-sdk
- @uipath/uipath-python-bridge
- @draftlab/db
- @uipath/ap-chat
- @uipath/project-packager
- @uipath/packager-tool-case
- @uipath/packager-tool-workflowcompiler-browser
- @uipath/packager-tool-connector
- @uipath/packager-tool-workflowcompiler
- @uipath/packager-tool-webapp
- @uipath/packager-tool-apiworkflow
- @uipath/packager-tool-functions
- ts-dna
- @uipath/widget.sdk
- @uipath/resources-tool
- cross-stitch
- @uipath/codedagents-tool
- @uipath/aops-policy-tool
- @uipath/solution-packager
- @draftlab/auth-router
- cmux-agent-mcp
- agentwork-cli
- @uipath/packager-tool-bpmn
- @draftauth/core
- @dirigible-ai/sdk
- @uipath/packager-tool-flow
- git-branch-selector
- wot-api
- git-git-git
- @beproduct/nestjs-auth
- @ml-toolkit-ts/xgboost
- nextmove-mcp
- ml-toolkit-ts
- @uipath/telemetry
- @draftauth/client
- @ml-toolkit-ts/preprocessing
- @tallyui/connector-medusa
- @uipath/tool-workflowcompiler
- @uipath/vss
- @tallyui/theme
- @tallyui/storage-sqlite
- @uipath/solutionpackager-sdk
- @tallyui/connector-vendure
- @tallyui/core
- @tallyui/connector-woocommerce
- @tallyui/components
- @uipath/ui-widgets-multi-file-upload
- @tallyui/pos
- @tallyui/database
- @supersurkhet/cli
- @tallyui/connector-shopify
- @tolka/cli
- @supersurkhet/sdk
- @uipath/access-policy-tool
- @uipath/context-grounding-tool
- @uipath/gov-tool
- @uipath/admin-tool
- @uipath/identity-tool
- @uipath/llmgw-tool
- @uipath/resourcecatalog-tool
- @uipath/functions-tool
- @uipath/access-policy-sdk
- @uipath/platform-tool
- npm
- GitHub Actions
- tanstack
- OpenID Connect
- Vault
Techniques named here
- Malicious npm preinstall/prepare lifecycle scripts
- Optional dependency abuse via Git-hosted package
- Failure-after-execution evasion
- Trusted publishing / OIDC abuse
- Worm propagation via package repacking and republishing
Threat actors named here
Related in Supply Chain


