ReadingResearchRadarInvestment framework
Sign in / Sign up
← Back to reading
NewsMaterial2 min readDisconfirmAI Editorial

AI Proxy Library LiteLLM Hit by Supply Chain Attack; Malicious v1.107.0 Steals Cloud and Model API Keys

Popular AI proxy library LiteLLM suffered a supply chain attack with malicious version v1.107.0 implanting credential stealers, threatening cloud and LLM API keys.

2026-10-21 21:44 GMT+8

Security firm Wiz Research disclosed on October 21, 2026, that the popular Python LLM proxy library LiteLLM was targeted by a supply chain attack. Attackers published a malicious version, v1.107.0, which remained available on PyPI for approximately two hours before being quarantined. Simultaneously, related image tags on GHCR and Docker Hub (including latest, main-latest, etc.) were trojanized until they were removed around 13:53 UTC. The most recent safe version is v1.106.2.

According to analyses by Wiz and Datadog Security Labs, the malicious package extracts three files (cook.pth, cook.py, and sitecustomize.py) into the site-packages root directory upon installation. These files are designed to execute automatically whenever a Python interpreter starts, triggering even if LiteLLM is not imported. Specifically, cook.py contains a credential stealer named privcollect, which harvests sensitive data across 16 modules targeting browser credentials from Chrome/Firefox, AWS/GCP/Azure cloud credentials, SSH/GPG keys, and API keys for LLM providers like OpenAI and Anthropic stored in environment variables or config files. It also directly queries the LiteLLM Proxy's PostgreSQL database to extract upstream provider credentials.

The harvested data is encrypted with AES-256-CBC and exfiltrated via HTTP POST requests to the attacker-controlled lookalike domain www.litellm[.]dev/healthcheck ↗. The sitecustomize.py file includes an hourly backdoor mechanism checking a GitHub dead drop to download second-stage RAT payloads, although no active payload was observed in the dead drop at the time of analysis. Wiz noted that this dual-technique approach using both .pth files and sitecustomize.py appears to be the first documented case in the wild.

Sign in / Sign up
ReadingResearchRadarInvestment framework

LiteLLM developer BerriAI stated that attackers used stolen GitHub CLI OAuth tokens from three engineers' accounts to trigger the legitimate build pipeline against a malicious fork repository (Berri-AI/litellm, noting the hyphen difference). Datadog added that this marks the second supply chain compromise of LiteLLM in 2026, following earlier incidents affecting versions 1.82.7 and 1.82.8 linked to TeamPCP activity, though no connection between the two compromises has been established yet.

Affected users should immediately manually remove the cook.pth, cook.py, and sitecustomize.py files from the site-packages directory, revert to v1.106.2, and rotate all potentially exposed cloud, AI, and browser credentials from a clean machine.

Sources

  • wiz.io↗
  • securitylabs.datadoghq.com↗
Continue researching →