As reported by The Hacker News, CrowdSec disclosed that an attacker copied approximately 170 of its private GitHub repositories using credentials stolen from a former employee's laptop—compromised not through CrowdSec's infrastructure, but through the May 2026 TanStack npm supply chain attack (CVE-2026-45321). The code surfaced on a public forum on September 16, roughly four months after the exfiltration.
This incident is a textbook demonstration of how supply chain compromises and identity lifecycle failures compound into serious breaches. The malicious npm packages didn't need to pivot into CrowdSec's AWS environment—they simply needed one lingering OAuth token on one machine that should have been deprovisioned.
Vulnerability Context: CVE-2026-45321
| CVE | CVE-2026-45321 |
| Type | Supply chain compromise — malicious npm package versions |
| Scope | 84 malicious versions across 42 TanStack npm packages published May 11, 2026 |
| Impact | Credential theft: GitHub tokens, SSH keys, cloud credentials from developer machines |
| Severity | Critical (credential exfiltration from development environments) |
| Known Victims | CrowdSec, Mistral AI, OpenAI (confirmed); others likely |
| Patch/Mitigation | Remove malicious package versions; rotate all exposed credentials; audit npm dependency trees |
| Active Exploitation | Yes — confirmed credential theft and downstream code exfiltration |
Where the Real Failure Occurred
The TanStack compromise was the initial access vector, but CrowdSec's breach was enabled by a failure that is entirely preventable and far more common than supply chain attacks: delayed deprovisioning of a departed employee's access.
The attacker copied the repositories on May 22—11 days after the malicious packages were published. CrowdSec didn't remove the former employee from its GitHub organization until May 25, and only learned of the leak months later. The token left no trace in GitHub logs CrowdSec could check.
Three compounding failures stand out:
Broader Implications
The fact that Mistral AI and OpenAI also confirmed developer device compromises through the same vector signals this was a wide-net attack with high yield. npm packages are ubiquitous in modern development, and credential-harvesting payloads embedded in popular libraries can reach thousands of machines within hours of publication.
The CrowdSec case is particularly notable because CrowdSec is itself a security company. If a firm that builds attack detection tooling can lose its private source code through a combination of supply chain compromise and offboarding gaps, the same scenario is playing out at non-security organizations with far less visibility.
The leaked material—including CrowdSec's consensus algorithm for IP blocklisting, web console code, and data science models—has competitive and potentially security implications. Even though CrowdSec states the code is four months old and has changed significantly, the architectural knowledge embedded in that code is durable.
Shield53 Recommendations
Immediate Actions
- Audit all npm dependencies against the TanStack advisory list. Remove or pin any compromised versions. Use
npm auditand cross-reference with the package publication dates around May 11, 2026. - Rotate all developer credentials if any machine installed a malicious TanStack package: GitHub personal access tokens, OAuth tokens, SSH keys, and any cloud provider credentials (AWS, GCP, Azure) stored on those machines.
- Review GitHub organization membership for any accounts belonging to departed employees, contractors, or inactive users. Remove them immediately.
- Revoke all existing OAuth tokens in your GitHub organization and require re-authentication. This forces any stolen tokens to become invalid.
Strategic Hardening
- Automate deprovisioning: Integrate HRIS offboarding events directly with GitHub, cloud IAM, and SSO to revoke access within hours—not days—of departure. No exceptions for "wrapping up work."
- Enforce short-lived credentials: Replace long-lived GitHub PATs with OIDC-based federation for CI/CD. Use ephemeral tokens wherever possible.
- Implement npm package integrity controls: Use
npm ciwith lockfiles, enable package provenance verification, and consider allowlisting registries or using a private npm proxy with curated package approvals. - Deploy endpoint detection on developer machines: Credential-harvesting payloads from npm install scripts can be detected through behavioral monitoring—look for processes that access
~/.ssh,~/.aws,~/.config/gh, or environment variables containing tokens. - Monitor GitHub audit logs centrally: Route GitHub organization audit logs to your SIEM. Large repository clones or unusual OAuth token usage should trigger alerts. Note that CrowdSec's token left no trace in the logs they could check—this highlights the need for GitHub Enterprise audit log streaming and API token inventory tools.
The lesson here is not that supply chain attacks are unstoppable. It's that the damage from a supply chain compromise is directly proportional to how much standing access and how many stale credentials exist in your environment. CrowdSec's attacker didn't need to defeat their infrastructure—they needed one token that should have already been dead.