LiteLLM Supply Chain Compromise on PyPI and Docker

LiteLLM Supply Chain Attack Steals Cloud and AI Service Keys

HIGH
October 22, 2026
October 26, 2026
4m read
Supply Chain AttackMalwareCloud Security

Related Entities(initial)

Organizations

Aikido

Products & Tech

Docker HubLiteLLMPyPI

Full Report(when first published)

Executive Summary

On October 21, 2026, the open-source AI gateway LiteLLM was the target of a significant supply chain attack, its second this year. Attackers compromised the project's release pipeline and published a malicious version, v1.107.0, to the PyPI package repository and Docker Hub. The trojanized package was engineered to steal a wide range of sensitive credentials from the environments where it was deployed, including cloud provider logins, developer secrets, and API keys for services like OpenAI and Anthropic. The malicious versions were active for several hours before being removed. Users and organizations are advised that simply updating is insufficient; a full rotation of all potentially exposed credentials is required.

Threat Overview

The attack represents a classic software supply chain compromise, where a trusted software distribution channel is used to deliver malware to downstream users. By compromising LiteLLM's release process, the attackers were able to push a malicious update that appeared legitimate. The malware's primary objective was credential harvesting, targeting high-value secrets commonly found in development and production environments that use AI services.

The malicious package was available during the following windows:

  • PyPI (litellm==1.107.0): October 21, 2026, from 11:39 to 13:23 UTC.
  • Docker Hub (tags v1.107.0, latest, main-latest, main-stable): October 21, 2026, from 11:46 to 14:20 UTC.

The last known safe version prior to the incident is v1.106.2.

Technical Analysis

The attack leveraged a Compromise Software Dependencies and Development Tools (T1195.001) technique. Once the malicious package was installed, it executed code designed to scan the environment for credentials. This included searching for:

  • Environment variables (e.g., AWS_ACCESS_KEY_ID, OPENAI_API_KEY).
  • Configuration files (e.g., ~/.aws/credentials).
  • Secrets within CI/CD pipeline contexts.

After harvesting the credentials, the malware would exfiltrate them to an attacker-controlled server. The package also included capabilities to load remote-code execution tools, allowing for potential second-stage attacks and persistence in the compromised environment.

Impact Assessment

The impact of this supply chain attack is potentially severe for any organization that downloaded and deployed the malicious version. LiteLLM is a popular tool used to manage and standardize interactions with various large language models (LLMs). As such, it is often deployed in environments with access to highly sensitive data and powerful API keys.

Compromised credentials could allow attackers to:

  • Access and steal data from cloud storage (e.g., AWS S3, Google Cloud Storage).
  • Incur significant financial costs by abusing expensive AI service APIs.
  • Gain a persistent foothold in the organization's cloud infrastructure.
  • Pivot to other systems and escalate privileges.

The incident underscores the significant risks associated with relying on open-source packages without proper security controls like dependency pinning and verification.

IOCs — Directly from Articles

No specific C2 domains, IPs, or file hashes were provided in the source articles.

Cyber Observables — Hunting Hints

Security teams should hunt for evidence of the malicious LiteLLM version in their environments.

Type
file_name
Value
requirements.txt / pyproject.toml
Description
Search for the string litellm==1.107.0 to identify projects that may have installed the malicious version.
Context
Code repositories, developer workstations
Type
log_source
Value
CI/CD build logs
Description
Review build logs from October 21 for pulls of litellm:1.107.0 or litellm:latest.
Context
CI/CD systems (e.g., Jenkins, GitLab CI)
Type
network_traffic_pattern
Value
Unexpected outbound connections from build agents or application servers to unknown IPs.
Description
Network Security Monitoring, VPC Flow Logs
Context
Type
log_source
Value
CloudTrail, Azure Activity Logs
Description
Audit for anomalous API calls made with keys associated with LiteLLM deployments around the time of the incident.
Context
Cloud provider audit logs

Detection & Response

  1. Identify Installations: Immediately scan all systems, container registries, and source code repositories for any instance of LiteLLM version 1.107.0 or Docker images pulled with the affected tags during the incident window.
  2. Isolate and Analyze: Isolate any systems found to be running the malicious version. Conduct forensic analysis to determine the extent of the compromise.
  3. Assume Credential Compromise: As advised by security researchers, any organization that installed the malicious version must assume all credentials in that environment are compromised.
  4. Rotate All Secrets: Initiate a full rotation of all potentially exposed secrets. This includes AWS/GCP/Azure keys, AI service API keys (OpenAI, Anthropic, etc.), database passwords, and any other secrets present in the environment.

Mitigation

  1. Update to a Safe Version: Remove the malicious version and update to the latest secure version of LiteLLM (or downgrade to v1.106.2 or older if an immediate update is not possible).
  2. Pin Dependencies: Implement dependency pinning in all projects. Instead of using latest tags or flexible version ranges, pin to a specific, known-good version hash (e.g., litellm==1.106.2). This prevents automatic updates to potentially malicious versions.
  3. Vendor Dependencies: Use a private package repository (e.g., Artifactory, Nexus) to vet and host approved versions of open-source dependencies, rather than pulling directly from public registries.
  4. Least Privilege: Run applications and build jobs with the minimum necessary permissions. Use dedicated, short-lived credentials for CI/CD pipelines to limit the impact of a compromise.

Timeline of Events

1
October 21, 2026
Malicious LiteLLM version v1.107.0 is published to PyPI.
2
October 21, 2026
Corresponding malicious Docker images are pushed to Docker Hub.
3
October 21, 2026
Malicious package is removed from PyPI.
4
October 21, 2026
Malicious Docker images are removed from Docker Hub.
5
October 22, 2026
This article was published

Article Updates

October 24, 2026

Severity increased

New analysis reveals the LiteLLM supply chain attack included a backdoor for remote code execution, increasing the potential for broader corporate network compromise and arbitrary command execution.

Further analysis of the LiteLLM supply chain attack (version 1.107.0) confirms the presence of a sophisticated backdoor in addition to the infostealer. This backdoor allows threat actors to execute arbitrary commands on compromised developer machines, significantly increasing the risk beyond credential theft. The incident now maps to additional MITRE ATT&CK techniques including T1555.005 (Credentials from Password Stores), T1059.006 (Python execution), and T1048 (Exfiltration Over Alternative Medium). This expanded capability means attackers could pivot into corporate networks, inject malicious code into company software, and exfiltrate proprietary data, escalating the overall severity and potential for widespread organizational impact.

October 26, 2026

New details on LiteLLM attack: GitHub tokens used, malware persists via Python startup hooks, RAT backdoor found.

New analysis reveals attackers compromised LiteLLM's release pipeline using stolen GitHub CLI OAuth tokens from project engineers. The malicious package achieved persistence by modifying Python startup hooks (sitecustomize.py, usercustomize.py), ensuring execution whenever Python starts, not just on library import. Beyond credential harvesting, the malware also included a remote access trojan (RAT) backdoor. Microsoft and Datadog provided detailed technical analysis, confirming the sophisticated nature of the attack and updating detection guidance.

Timeline of Events

1
October 21, 2026

Malicious LiteLLM version v1.107.0 is published to PyPI.

2
October 21, 2026

Corresponding malicious Docker images are pushed to Docker Hub.

3
October 21, 2026

Malicious package is removed from PyPI.

4
October 21, 2026

Malicious Docker images are removed from Docker Hub.

Sources & References(when first published)

Article Author

Jason Gomes

Jason Gomes

• Cybersecurity Practitioner

Cybersecurity professional with over 10 years of specialized experience in security operations, threat intelligence, incident response, and security automation. Expertise spans SOAR/XSOAR orchestration, threat intelligence platforms, SIEM/UEBA analytics, and building cyber fusion centers. Background includes technical enablement, solution architecture for enterprise and government clients, and implementing security automation workflows across IR, TIP, and SOC use cases.

Threat Intelligence & AnalysisSecurity Orchestration (SOAR/XSOAR)Incident Response & Digital ForensicsSecurity Operations Center (SOC)SIEM & Security AnalyticsCyber Fusion & Threat SharingSecurity Automation & IntegrationManaged Detection & Response (MDR)

Editorial Standards & Analyst Review

CyberNetSec.io uses automation to assist source monitoring, deduplication, observable extraction, and structured intelligence generation. Published analysis follows human-defined editorial standards and adds defensive context including MITRE ATT&CK, D3FEND, STIX, and Sigma where applicable. Read our editorial policy.

Tags

AI SecurityCredential TheftDockerOpen SourcePyPI

📢 Share This Article

Help others stay informed about cybersecurity threats

🎯 MITRE ATT&CK Mapped

Every tactic, technique, and sub-technique used in this threat has been identified and mapped to the MITRE ATT&CK framework for consistent, actionable threat language.

🧠 Enriched & Analyzed

Observables and indicators of compromise (IOCs) have been extracted and cataloged. Risk has been assessed and correlated with known threat actors and historical campaigns.

🛡️ Actionable Guidance

Detection rules, incident response steps, and D3FEND-aligned mitigation strategies are included so your team can act on this intelligence immediately.

🔗 STIX Visualizer

Structured threat data is packaged as a STIX 2.1 bundle and can be visualized as an interactive graph — relationships between actors, malware, techniques, and indicators.

⚡ Sigma Generator

Sigma detection rules are derived from the threat techniques in this article and can be converted for deployment across any major SIEM or EDR platform.