LiteLLM
- Type
- Infostealer
- Capabilities
- Credential theftSession hijackingExfiltrationPersistenceDefense evasionReconnaissance
- Platforms
- WindowsLinuxmacOS
LiteLLM is a legitimate Python interface and proxy for large language model providers that was abused to distribute credential-stealing malware through compromised releases in 2026. The malicious artifacts targeted developer workstations, CI/CD runners, and AI-service deployments; the package name identifies the compromised software rather than a distinct malware family.
In March 2026, TeamPCP used publishing credentials stolen from LiteLLM’s CI/CD environment during the Trivy supply-chain campaign to publish malicious versions 1.82.7 and 1.82.8 to PyPI. Version 1.82.8 introduced a Python startup hook that executed the payload without requiring an application to import LiteLLM. The payload stole credentials and supported persistent command retrieval through a user-level service on some Linux systems.
A separate compromise on October 21, 2026 distributed malicious version 1.107.0 through PyPI and container images on Docker Hub and GitHub Container Registry. This release combined two Python startup mechanisms to execute an information stealer and a detached remote-code loader. The stealer used 16 collection modules targeting cloud credentials, AI-provider API keys, developer-tool authentication material, browser credential and cookie databases, private keys, environment variables, shell histories, and host information. It also attempted to extract stored provider credentials from LiteLLM proxy databases. Collected data was encrypted using AES-256-CBC with an RSA-4096-wrapped key and transmitted to attacker-controlled infrastructure. The separate loader periodically consulted a GitHub-hosted pointer to locate and execute additional Python code, although no operational second-stage payload was observed during analysis.
Affected October artifacts covered Windows, Linux, and macOS, while the detached loader operated on Linux and macOS. Subsequent abuse of stolen AWS credentials included identity checks and AI-model enumeration consistent with LLMjacking. The October incident has not been established as a TeamPCP operation.
Associated vulnerabilities
1 CVE Mallory has correlated with this family across public research and vendor advisories. Each card links to the full Mallory page for that vulnerability.
Associated threat actors
1 distinct threat actor Mallory has associated with this family across public reporting. Open in Mallory to see the full evidence chain and overlapping campaigns.
Intrinsec’s report, section 4.1.4 , also describes the TeamPCP-attributed compromise, malicious LiteLLM versions 1.82.7 and 1.82.8, and Ghosty-hosted exfiltration infrastructure.
Techniques & procedures
39 distinct techniques documented for this family, organized by ATT&CK tactic.
Initial Access
8 techniques
Initial Access
Using these stolen publish tokens, the attackers hit PyPI to push versions 1.82.7 and 1.82.8 of LiteLLM... It authenticated to the GitHub API using the victim’s own stolen PAT
The attackers validated cloud keys taken from the Trivy, LiteLLM, and Checkmarx KICS compromises and used them to access cloud services, enumerate infrastructure, run commands inside containers, and exfiltrate sensitive data.
Following LiteLLM-driven credential theft, attackers reportedly use a compromised Tailscale VPN credential for initial access to Mercor’s infrastructure.
The irony is that Mercor was hacked via a third-party open source tool called LiteLLM.
Earlier this month, Mercor said that it was "one of thousands of companies" affected by the LiteLLM supply-chain attack.
The severity of this dependency was demonstrated in March 2026, when attackers compromised the LiteLLM package through dependency confusion, injecting malicious code directly into the request-handling pipeline of every deployment that pulled the poisoned release.
“That specific attack originated through a sophisticated supply chain compromise involving the LiteLLM library. In March 2026, malicious actors aggressively distributed a thoroughly compromised version of this critical library specifically designed to harvest sensitive credentials.”
By abusing valid credentials and trusted CI/CD workflows, attackers are bypassing traditional security controls, enabling widespread access across build systems, cloud infrastructure, and customer environments.
Execution
6 techniques
Execution
POST /mcp-rest/test/connection и POST /mcp-rest/test/tools/list принимали конфигурацию с полями command, args и env для stdio-транспорта. При подключении LiteLLM выполнял указанную команду.
Version 1.82.8 escalated - it added a litellm_init.pth file to site-packages that executes during every Python interpreter startup, not just when LiteLLM is imported.
We found 474 repositories that run a malicious version of trivy-action.
The LiteLLM payload bypassed standard SAST tools through a technique known as .pth file injection . When a package containing a .pth file is installed in the Python site-packages directory, the interpreter automatically reads it during initialization before the primary script is ever executed or imported.
The malware leveraged a .pth file, which executes automatically during Python interpreter startup. This means the payload runs in most Python processes without needing the package to be explicitly imported...
This means organisations running automated CI/CD pipelines may have unknowingly pulled the malicious code during that brief period.
Persistence
9 techniques
Persistence
Version 1.82.8 escalated - it added a litellm_init.pth file to site-packages that executes during every Python interpreter startup... any Python process on the machine triggered the malware.
Using these stolen publish tokens, the attackers hit PyPI to push versions 1.82.7 and 1.82.8 of LiteLLM... It authenticated to the GitHub API using the victim’s own stolen PAT
The attackers validated cloud keys taken from the Trivy, LiteLLM, and Checkmarx KICS compromises and used them to access cloud services, enumerate infrastructure, run commands inside containers, and exfiltrate sensitive data.
Following LiteLLM-driven credential theft, attackers reportedly use a compromised Tailscale VPN credential for initial access to Mercor’s infrastructure.
These packages contained credential-stealing and backdoor code designed to harvest SSH keys, cloud credentials, Kubernetes secrets, database credentials, environment variables, and other sensitive data, while establishing persistent access to attacker-controlled infrastructure.
Finally, the payload installed a systemd backdoor service that polled attacker-controlled infrastructure for additional binaries.
sysmon.service installed as persistent systemd user service
Finally, the payload installed a systemd backdoor service that polled attacker-controlled infrastructure for additional binaries.
.pth file auto-executes on every Python interpreter startup without user action
Privilege Escalation
8 techniques
Privilege Escalation
Version 1.82.8 escalated - it added a litellm_init.pth file to site-packages that executes during every Python interpreter startup... any Python process on the machine triggered the malware.
Using these stolen publish tokens, the attackers hit PyPI to push versions 1.82.7 and 1.82.8 of LiteLLM... It authenticated to the GitHub API using the victim’s own stolen PAT
The attackers validated cloud keys taken from the Trivy, LiteLLM, and Checkmarx KICS compromises and used them to access cloud services, enumerate infrastructure, run commands inside containers, and exfiltrate sensitive data.
Finally, the payload installed a systemd backdoor service that polled attacker-controlled infrastructure for additional binaries.
sysmon.service installed as persistent systemd user service
Finally, the payload installed a systemd backdoor service that polled attacker-controlled infrastructure for additional binaries.
.pth file auto-executes on every Python interpreter startup without user action
Privileged Kubernetes pod with host filesystem mount created in kube-system
Stealth
5 techniques
Stealth
The TeamPCP payload dropped a heavily obfuscated Base64-encoded execution string into a hidden .pth file ... During the Bitwarden CLI compromise on April 22, the core payload bw1.js was a massive 9.7 MB file processed through obfuscator.io, utilizing a 43,436-entry string lookup table
Using these stolen publish tokens, the attackers hit PyPI to push versions 1.82.7 and 1.82.8 of LiteLLM... It authenticated to the GitHub API using the victim’s own stolen PAT
The attackers validated cloud keys taken from the Trivy, LiteLLM, and Checkmarx KICS compromises and used them to access cloud services, enumerate infrastructure, run commands inside containers, and exfiltrate sensitive data.
The LiteLLM payload bypassed standard SAST tools through a technique known as .pth file injection . When a package containing a .pth file is installed in the Python site-packages directory, the interpreter automatically reads it during initialization before the primary script is ever executed or imported.
The malware leveraged a .pth file, which executes automatically during Python interpreter startup. This means the payload runs in most Python processes without needing the package to be explicitly imported...
Credential Access
6 techniques
Credential Access
When the compromised action ran, it harvested LiteLLM’s PyPI publishing token.
Harvest : SSH keys, cloud credentials, Kubernetes secrets, crypto wallets, Slack/Discord tokens
Especially, it did not collect the CI secrets if those were not explicitly set as environment variables.
Harvest : SSH keys, cloud credentials, Kubernetes secrets, crypto wallets, Slack/Discord tokens - and actively queried AWS APIs using stolen IMDS credentials.
The payload searched for and exfiltrated over 50 categories of secrets... crypto wallet keys... and API credentials...
The common thread among those incidents is that they all revolved around secrets, one way or another. Some used secrets as an initial access vector, and others were focused on collecting secrets from victim environments.
Discovery
2 techniques
Discovery
The attackers validated cloud keys taken from the Trivy, LiteLLM, and Checkmarx KICS compromises and used them to access cloud services, enumerate infrastructure...
In Kubernetes, search for node-setup-* pods in kube-system.
Lateral Movement
1 technique
Lateral Movement
plus Kubernetes lateral movement deploying privileged pods across every node in the cluster.
Collection
3 techniques
Collection
The TeamPCP malware specifically sought out these directories, intercepting proprietary prompts and unencrypted model weights directly from the development lifecycle.
Following LiteLLM-driven credential theft, attackers reportedly use a compromised Tailscale VPN credential for initial access to Mercor’s infrastructure. Lateral movement and data staging begin.
Mercor lost roughly 4 terabytes of data through the LiteLLM open-source AI gateway, exposing training methodologies for OpenAI, Anthropic, and Meta in the process.
Command and Control
3 techniques
Command and Control
Exfiltration domain models.litellm[.]cloud C2 domain checkmarx[.]zone
Déploiement de proxies inverses et de workloads agentiques (framework Manus, Node.js custom, LiteLLM gateways)
the payload installed a systemd backdoor service that polled attacker-controlled infrastructure for additional binaries.
Exfiltration
2 techniques
Exfiltration
Exfiltrate : AES-256 encrypted, sent to models.litellm[.]cloud
execute commands in containers, and exfiltrate sensitive cloud data... Reviewing cloud logs for unexpected Amazon Simple Storage Service access, and Secrets Manager retrievals.
Observables
1 indicator attributed across vendor reports, sandbox runs, and researcher write-ups. Values are masked here and available in full in Mallory.
Recent activity
14 sources tracked across advisories, community write-ups, and news. New activity surfaces here as Mallory finds it.