litellm 1.82.7 and 1.82.8 on PyPI held a three-stage credential stealer that started every time Python ran, published by TeamPCP on 24 March 2026.
Version 1.82.6 is the last clean release, according to BleepingComputer. The attack followed the Trivy compromise five days earlier.
What happened
The attackers stole the LiteLLM PyPI publishing token and published two poisoned versions.
- LiteLLM's CI ran the Trivy GitHub Action without a pinned version. The poisoned action read the
PYPI_PUBLISHtoken from the runner. - The attackers published to PyPI directly. The malicious code was absent from the GitHub source.
- Version 1.82.7 added a base64 blob to
litellm/proxy/proxy_server.py. Version 1.82.8 addedlitellm_init.pth, which runs at every Python start. - The code sent SSH keys, cloud and Kubernetes credentials,
.envfiles, TLS keys, CI secrets and crypto wallets tomodels.litellm.cloud. - It then installed a systemd backdoor that polls
checkmarx.zone/rawevery 50 minutes.
The attackers published 1.82.7 at 10:39 UTC and 1.82.8 at 10:52 UTC on 24 March 2026. PyPI quarantined both after about three hours.
Affected versions
- litellm 1.82.7 (malicious).
- litellm 1.82.8 (malicious).
- litellm 1.82.6 is the last clean release.
- Treat any machine that ever had 1.82.7 or 1.82.8 as compromised.
Indicators of compromise
- SHA-256 of
litellm_init.pth:71e35aef03099cd1f2d6446734273025a163597de93912df321ef118bf135238. - Domains:
models.litellm.cloudandcheckmarx.zone. - Archive name:
tpcp.tar.gz. - Files:
~/.config/sysmon/sysmon.py,~/.config/systemd/user/sysmon.service,/tmp/pglog,/tmp/.pg_state. - Kubernetes pods named
node-setup-<node name>inkube-system.
How to check
Use a shell outside the affected Python environment. Replace the path with that environment’s location.
find /path/to/environment \( -name 'litellm-*.dist-info' -o -name 'litellm_init.pth' \) -print
Check for the unexpected service and files on the host.
ls -l ~/.config/sysmon/sysmon.py ~/.config/systemd/user/sysmon.service /tmp/pglog /tmp/.pg_state systemctl --user status sysmon.service
Check CI build logs and lockfile history for past installs. A clean install today cannot rule out earlier exposure.
What to do now
- Isolate affected hosts and runners. Stop the unexpected service before you reuse the host.
- Rebuild from a clean release. Review cached builds and follow LiteLLM’s recovery guidance for Kubernetes.
- Use a clean machine to rotate credentials the affected host or runner can read.
- Block
models.litellm.cloudandcheckmarx.zoneat the firewall or DNS resolver.
What Vigilance would show
These examples show an install hold and the corresponding owner report.
Example install message
Vigilance blocked `litellm` 1.82.7. This version is too new or changed in a way Vigilance must check first.
Example owner report
Bad update
litellm 1.82.7
An AI gateway gained hidden code that stole cloud keys and login files, and started itself every time Python ran.
No security team? See who reads the alert.
Frequently asked questions
Is uninstalling LiteLLM enough?
No. The malware leaves a systemd service and can leave pods in kube-system. Remove those, then rotate every credential.
Which LiteLLM versions were compromised?
Versions 1.82.7 and 1.82.8. Version 1.82.8 added the file that runs at every Python start.
How can I stop the next PyPI attack?
Pin GitHub Actions by commit SHA. Pin Python packages to exact versions in a lock file.
Sources
- docs.litellm.ai/blog/security-update-march-2026
- bleepingcomputer.com/news/security/popular-litellm-pypi-package-compromised-in-teampcp-supply-chain-attack/
- research.jfrog.com/post/litellm-compromised-teampcp/
- snyk.io/blog/poisoned-security-scanner-backdooring-litellm/
- endorlabs.com/learn/teampcp-isnt-done
- microsoft.com/en-us/security/blog/2026/03/24/detecting-investigating-defending-against-trivy-supply-chain-compromise/
Send this page to the person who looks after AI at your company.