March 24, 2026 · 4 min read

LiteLLM Supply Chain Attack: Your AI Project Might Be Compromised

636 upvotes on Hacker News in 5 hours. One malicious package. And if you're building with Python + LLMs, you need to check your system right now.

This morning, the LiteLLM team confirmed a critical supply chain attack. Version 1.82.8 of their popular Python package — used by thousands of developers to connect to OpenAI, Anthropic, Google, and other LLM APIs — was compromised with a credential-stealing payload.

Here's what happened, who's affected, and what you need to do.

⚠️ CRITICAL: Affected Version

litellm==1.82.8 — If you have this installed on any system, treat it as compromised.

How the Attack Worked

This wasn't your typical "inject malicious code into an import" attack. It was way more sophisticated — and way more dangerous.

The attacker planted a .pth file in the package. If you're not familiar with Python internals: .pth files in site-packages/ are executed automatically every time Python starts. You don't even need to import litellm.

Just having the package installed was enough.

The payload was double base64-encoded (invisible to a simple grep), then it:

  1. Collected everything — system info, environment variables, SSH keys, git credentials, cloud configs (AWS, GCP, Azure, Kubernetes), Docker configs, shell history, crypto wallets, SSL keys, database credentials, CI/CD secrets, and Slack/Discord webhooks
  2. Encrypted it — AES-256 with a random key, then the key encrypted with a hardcoded 4096-bit RSA public key
  3. Exfiltrated it — sent everything to models.litellm.cloud (NOT the official litellm.ai domain)

Why This Was So Clever

The attacker chose a supply chain target, not a direct attack. If you're an indie hacker building AI tools, LiteLLM is probably in your stack. That means your API keys, SSH access, and cloud credentials are exactly what they wanted.

This is an attack on indie hackers and builders. Not enterprise. Us.

What They Stole

The full list of targeted data:

SSH keys (all types)
Git credentials
AWS credentials
GCP credentials
Azure credentials
Kubernetes secrets
Docker configs
npm / .netrc
Shell history
Crypto wallets
SSL private keys
CI/CD secrets
Database configs
Webhook URLs
All env vars

Yeah. Everything. If this ran on your dev machine, your laptop, your CI pipeline, or your Docker container — it's all gone.

What You Need to Do Right Now

Immediate Actions (do this now)

  • 🔴 Run pip list | grep litellm — check if you have 1.82.8
  • 🔴 Check site-packages/ for litellm_init.pth
  • 🔴 If affected: rotate ALL credentials that existed on that machine
  • 🟡 Check your pip cache: pip cache list | grep litellm
  • 🟡 Review any systems that pulled from PyPI recently
  • 🟢 Upgrade to a known-safe version or pin a different version

Don't just uninstall. If the payload ran even once, the credentials are gone. Uninstalling doesn't undo the exfiltration. Rotate everything.

The Bigger Picture

Supply chain attacks are the real security risk for indie hackers. We don't have a security team auditing every dependency. We run pip install and keep building.

LiteLLM is used by thousands of developers — it's one of the most popular Python packages for working with LLM APIs. It abstracts away the chaos of dealing with OpenAI, Anthropic, Google, Mistral, and 100+ other providers through a single API.

The attacker knew exactly who they were targeting: builders with API keys, cloud access, and valuable data.

This is the second major Python supply chain attack in recent months. Remember the ultralytics compromise? The python3-pip namespace hijacking? It keeps happening.

How to Protect Yourself Going Forward

Some basic hygiene that actually matters:


As indie hackers, we move fast. We install, we build, we ship. But today's attack is a reminder: the packages we trust are attack surfaces too.

Check your system. Rotate your keys. Stay paranoid.

Want to Build AI Agents That Actually Stay Secure?

The Ultimate Setup guide covers the complete indie hacker AI stack — including security practices that keep your projects safe.

Get the Ultimate Setup → $29

Sources: GitHub Issue #24512 · Hacker News