Axios HTTP Library Compromised on NPM: Malicious Versions Drop Cross-Platform Remote Access Trojan
The Axios HTTP client library — the most popular JavaScript HTTP library with over 100 million weekly downloads — was compromised on NPM in a highly sophisticated supply chain attack.
What Happened
- Malicious versions:
axios@1.14.1andaxios@0.30.4published to NPM - Attack vector: Injected fake dependency
plain-crypto-js@4.2.1(never imported in source) - Payload: Cross-platform Remote Access Trojan (RAT) for macOS, Windows, and Linux
- Detection: StepSecurity AI Package Analyst and Harden-Runner
Why This Is Extraordinary
This was among the most operationally sophisticated supply chain attacks ever documented against a top-10 NPM package:
- Pre-staged: The malicious dependency was created 18 hours in advance
- Multi-platform: Three separate payloads pre-built for macOS, Windows, and Linux
- Coordinated: Both release branches poisoned within 39 minutes of each other
- Self-destructing: Malware erases itself and replaces package.json with a clean version
- Speed: Within 2 seconds of
npm install, the malware was already calling home to the C2 server - Zero footprint: No malicious code inside axios itself — entirely hidden in the dependency
Impact
- Backstage developer portal framework flagged C2 callbacks in CI/CD
- C2 domain:
sfrclak.com:8000 - 12,000+ public repositories use Harden-Runner which detected the anomaly
Analysis
This attack represents a new level of sophistication in software supply chain attacks. The attacker didn't just push malicious code — they orchestrated a multi-stage, multi-platform, self-destructing operation that could evade forensic analysis.
The key lesson: dependency inspection is insufficient when the malicious payload is in a dependency of a dependency, and that dependency self-destructs after execution. Organizations need runtime behavioral analysis (like Harden-Runner's anomaly detection) to catch these attacks.
For the 100 million+ weekly Axios users: check your package-lock.json and ensure you're not running versions 1.14.1 or 0.30.4.