# LiteLLM 1.82.7 and 1.82.8 on PyPI carried a credential stealer after CI release secrets leaked

Source: https://botpassword.com/incidents/2026-03-litellm-pypi-1-82-7-1-82-8
Disclosed: 2026-03-24 · Type: Supply chain · Status: Resolved · Updated: 2026-10-25

On 24 March 2026 malicious `litellm` versions 1.82.7 and 1.82.8 were published to PyPI and were live for about 40 minutes before PyPI quarantined them. LiteLLM says its PyPI, GHCR and Docker publishing credentials were exposed through a compromised, unpinned Trivy dependency in its CI. Datadog found the payload harvested cloud keys, SSH keys, Kubernetes data and CI secrets; anyone who installed either version should treat the host as compromised and rotate what it could reach.

## What was exposed

According to Datadog Security Labs, the payload collected environment variables, SSH keys, cloud credentials, Kubernetes data, Docker configs, shell history, database credentials, wallet files and CI/CD secrets, encrypted them with an AES-256 session key wrapped in RSA-4096, and sent them to `models.litellm[.]cloud`. In 1.82.7 the code sat in `litellm/proxy/proxy_server.py` and ran when the proxy module was used. In 1.82.8 a `litellm_init.pth` file ran it at every Python interpreter start, whether or not LiteLLM was imported. Datadog also describes persistence through `~/.config/sysmon/sysmon.py` and a user systemd unit, and, where a Kubernetes service-account token was usable, privileged `node-setup-*` pods. LiteLLM is a gateway that typically holds API keys for many model providers, so environments running it often have several provider keys in their environment.

## Who is affected

You are affected if any machine, container or CI job installed `litellm==1.82.7` or `litellm==1.82.8` on 24 March 2026, including through an unpinned dependency. Check lockfiles, `pip freeze` output and image build logs. On hosts, look for `litellm_init.pth` in site-packages, `~/.config/sysmon/sysmon.py`, `~/.config/systemd/user/sysmon.service`, `/tmp/pglog` or `/tmp/.pg_state`. In Kubernetes, look for unexpected `node-setup-*` pods. Datadog suggests also checking services pinned to 1.82.6 that may have floated during the window.

## What to do

1. Treat affected hosts as compromised: rebuild them from known-good images rather than only reinstalling the package.
2. Rotate every credential the host or job could read, prioritizing package publishing tokens, CI/CD secrets, cloud and Kubernetes credentials, and the model provider keys LiteLLM was configured with.
3. Remove the persistence files and any `node-setup-*` pods, and review Kubernetes audit logs for secret access.
4. Block `models.litellm[.]cloud` and `checkmarx[.]zone` at egress and hunt for past connections.
5. Pin `litellm` to a verified version and verify GHCR images with cosign as LiteLLM describes.

## Keys to rotate

- [OpenAI](https://botpassword.com/keys/openai)
- [Anthropic](https://botpassword.com/keys/anthropic)
- [AWS (IAM access keys)](https://botpassword.com/keys/aws)
- [Google Cloud (service account keys and API keys)](https://botpassword.com/keys/google-cloud)
- [Azure (Microsoft Entra app client secrets)](https://botpassword.com/keys/azure)
- [PyPI](https://botpassword.com/keys/pypi)
- [GitHub](https://botpassword.com/keys/github)

## Timeline

- 2026-03-24: LiteLLM v1.82.7 is pushed to PyPI at 10:39 UTC and v1.82.8 soon after; PyPI quarantines them after about 40 minutes, and they are deleted by 16:00 UTC. ([source](https://docs.litellm.ai/blog/security-townhall-updates))
- 2026-03-27: Datadog Security Labs reports malicious Telnyx 4.87.1 and 4.87.2 on PyPI in the same campaign. ([source](https://securitylabs.datadoghq.com/articles/litellm-compromised-pypi-teampcp-supply-chain-campaign/))
- 2026-03-27: LiteLLM publishes its security town hall update: forensics with Mandiant, no malicious code on `main`, no lateral movement found, credentials rotated, releases paused. ([source](https://docs.litellm.ai/blog/security-townhall-updates))

## Indicators

- `litellm` 1.82.7 and 1.82.8 on PyPI; `litellm_init.pth` in site-packages.
- `~/.config/sysmon/sysmon.py` and `~/.config/systemd/user/sysmon.service`.
- Connections to `models.litellm[.]cloud` with header `X-Filename: tpcp.tar.gz`, or polling of `checkmarx[.]zone/raw`.

## Sources

- https://docs.litellm.ai/blog/security-townhall-updates
- https://securitylabs.datadoghq.com/articles/litellm-compromised-pypi-teampcp-supply-chain-campaign/
