Weekly caseNovember 10, 2026Security

Published November 10, 2026 · Confidence: high · Complexity 8/10

LiteLLM v1.107.0 supply-chain attack: unrevoked master key led to stolen GitHub tokens and a poisoned release

A master key accidentally committed to a public repository on May 27, 2026 was spotted and flagged for revocation but never actually revoked. More than four months later an attacker used it to enter LiteLLM's Agent Platform, steal a GitHub organization owner's token plus two maintainers' tokens, and publish a compromised litellm 1.107.0 to PyPI and container registries on October 21, 2026.

Investigation trace
Part I · Reported facts (Source extraction)

Facts, hypotheses, timeline steps, and evidence reconstructed directly from the public incident record.

01 / Observed failure

Problem statement

On October 21, 2026, LiteLLM's release pipeline published a compromised litellm 1.107.0 containing compiled malware that steals credentials, built from an attacker-controlled fork, after a chain of credential thefts that began with an unrevoked master key exposed in May.

02 / Starting hypotheses

What investigators first believed

  • Deleting the exposed file removed the exposure, so the leaked key was no longer a risk.
  • The stolen GitHub tokens were taken from the logs of an internal LiteLLM deployment.
  • Branch protection and a two-person release gate would block an unauthorized release even with a stolen token.
  • A release built and signed by the normal pipeline could be trusted as coming from the real source repository.
03 / Investigation path

How the diagnosis unfolded

  1. 01

    On May 27, 2026, a config file containing the Agent Platform master key was committed to the public LiteLLM-Labs/lite-harness repo; a follow-up commit deleted the file about three hours later and the keys were identified as needing revocation, but the original commit stayed in the repository's public history until October 22.

    The exposure was spotted quickly, but revocation of the master key never actually happened.

  2. 02

    On October 10, the attacker called the Agent Platform API with the master key from 69.48.229.143; at 21:27:10 UTC a request to GET /api/v1/managed_agents/agents?limit=100 returned every managed agent's configuration.

    The response contained the GitHub CLI OAuth token of a GitHub organization owner, giving owner-level access to all repos.

  3. 03

    Using the owner's token, the attacker pushed throwaway branches (ci-tmp-a351cc, ci-tmp-be33e9) whose workflows posted CI secrets to a webhook.site endpoint, then deleted the runs.

    Two more maintainers' GitHub CLI tokens were stolen: GH_TOKEN and RELEASE_PLEASE_TOKEN.

  4. 04

    Investigators first suspected the tokens came from internal deployment logs, then checked the request logs and audit-log token hashes against the tokens used in later steps.

    The logs proved the first token came from the Agent Platform API, not deployment logs, correcting the early account.

  5. 05

    On October 21, the attacker pushed commit 9cf97e9 to BerriAI/project-releaser; it was first rejected by branch protection, then pushed by overriding protection with the owner's token, repointing the release source at the lookalike Berri-AI/litellm fork.

    The staging workflow built from fork commit 20535d8f, and a relaxed release gate let one stolen token trigger and another approve the production release.

  6. 06

    Seven litellm 1.107.0 wheels were published to PyPI at 11:39:51-11:40:13 UTC and container images at 11:46:56 UTC; an external researcher flagged the compromise within about 20 minutes.

    PyPI quarantined 1.107.0 by 13:23 UTC and Docker images were removed or repointed by 14:20 UTC.

  7. 07

    LiteLLM locked its registries, removed all org members except one account they were confident was unaffected and temporarily promoted to owner, and assumed every token, key, or authenticator was exfiltrated.

    Containment was established while investigators traced every token the attacker could have reached and revoked them.

  8. 08

    On October 22, the Socket team shared its independent investigation of the malicious workflows, and LiteLLM published this canonical attack-chain report on October 23.

    The Socket findings corroborated the October 10 exfiltration timeline and the token-hash links to the release approval and run deletions.

04 / Diagnostic evidence

What narrowed the fault domain

rollout change history

The May 27 commit of opencode.json with the Agent Platform master key to a public repo; a follow-up commit deleted the file, but the original commit stayed in public history until October 22 and the key was never revoked.

The more-than-four-month-old exposure stayed live and became the attacker's entry point on October 10.

protocol native evidence

Agent Platform API request at 21:27:10 UTC on October 10 to GET /api/v1/managed_agents/agents?limit=100 returning all agent configurations.

That single response handed over the organization owner's GitHub CLI token.

time correlated telemetry

GitHub audit-log token hashes behind each attacker action, matched against the hashes of GH_TOKEN and RELEASE_PLEASE_TOKEN.

The hash matches proved the stolen CI secrets were the tokens that approved the release and deleted the run records.

external observation

External researcher LidorMachluf published issue #47826 identifying the compromise at 12:06:41 UTC on October 21, within about 20 minutes of publication.

Outside detection was faster than internal detection for the poisoned release itself.

customer symptom

The poisoned 1.107.0 wheels and images were live on public registries for about two hours before being pulled.

The exposure window was short but real, which is why the incident post lists affected artifacts and cleanup steps.

dependency health signal

The attacker's October 12 second round of exfiltrations across private repos, plus attempts to identify upstream inference API tokens.

The blast radius extended beyond the release path, justifying the assume-everything-exfiltrated revocation.

Dead ends

The first incident post suspected the tokens were taken from the logs of an internal LiteLLM deployment; request logs later showed the first token came from the Agent Platform API instead.

The attacker first tried to subvert the releaser repository through the normal approval path and was blocked by heavily restricted approvals, so that quieter route failed and they switched to the noisier branch-protection override.

Assuming deleting the exposed file closed the leak, when only revocation would have done so — the original commit stayed in public history until October 22.

05 / Direction changes

Key turning points

  1. Checking request logs and audit-log token hashes, which moved the first-token theft from internal deployment logs to the Agent Platform API and corrected the early account.
  2. Matching the GH_TOKEN hash to the token that approved the production gate, which proved the October 10 exfiltration directly enabled the October 21 release.
  3. Recognizing that GitHub serves a fork's commits through the forked-from repository, so commit 20535d8f looked like it belonged to BerriAI/litellm while existing only on the Berri-AI fork.
  4. Realizing the relaxed release gate (any two engineers instead of a physical-device-locked account) let two stolen tokens trigger and approve the release.
06 / Mechanism

Root cause

An exposed master key was identified for revocation but never revoked, and the Agent Platform it unlocked held an unscoped, person-owned GitHub CLI token; that combination turned a single leaked key into owner-level GitHub access, further token theft via CI, and a poisoned release once branch protection and the release gate were bypassed or relaxed.

07 / Restoration

Resolution

PyPI quarantined litellm 1.107.0 by 13:23 UTC and Docker images were removed or repointed by 14:20 UTC on October 21; registries were locked, org membership was reset to a single unaffected owner account, every token was treated as exfiltrated and revoked, and the canonical attack-chain report was published October 23 with process improvements promised the following week.

Lessons from the response

  • Revocation is the fix for an exposed secret; deleting the file is not, and the revocation must be verified, not just flagged.
  • Never give an automation platform a person-owned, unscoped token: use a scoped service account so one leak cannot become owner-level access.
  • GitHub CLI OAuth tokens are post-2FA and skip sudo-mode reauthentication, so they deserve the same protection as owner credentials.
  • Audit-log token hashes can prove which stolen secret performed which action; use them to link exfiltration to later abuse instead of guessing.
  • Relaxing a release gate for shipping speed must be treated as a security change, because two stolen tokens can then replace the intended approver.
  • Verify the release source repository, not just the pipeline: a lookalike org name (Berri-AI vs BerriAI) is enough to redirect a build.
Part II · Analyst synthesis (Casebook commentary)

Reusable diagnostic principles, high-value signals, and anti-patterns synthesized from the reported facts above.

08 / Reusable reasoning · Analyst synthesis

Troubleshooting principles

  1. 01

    A leaked secret stays leaked until revocation is verified; deletion of the leak's container is not revocation.

  2. 02

    Let the logs arbitrate between competing hypotheses, especially the first one published under pressure.

  3. 03

    One owner-level credential collapses every downstream control, so protect the credential, not just the controls.

  4. 04

    The release artifact is only as trustworthy as the source it was built from.

Effective techniques

  • Correlating audit-log token hashes across steps to prove the same stolen secret approved the release and deleted the runs.
  • Using request logs to correct an early hypothesis instead of defending it, moving the theft from deployment logs to the Agent Platform API.
  • Treating the whole credential estate as compromised once owner access was confirmed, rather than revoking only the visibly abused tokens.
  • Publishing a canonical report that explicitly supersedes earlier, partially wrong status updates.

High-value evidence sources

  • API request logs with timestamps, IPs, and response contents for the October 10 Agent Platform calls.
  • GitHub audit logs with token hashes linking actions to specific stolen secrets.
  • CI workflow run records and their deletion timestamps on the throwaway branches.
  • External researcher and Socket reports that independently corroborated the internal timeline.

Common diagnostic traps

  • Treating removal of the exposed file as remediation while the key itself stayed valid for more than four months.
  • Storing a person-owned, unscoped GitHub token in an automation platform instead of a scoped service account.
  • Relaxing a physical-device release gate for release velocity without a compensating control.
  • Trusting a pipeline-built artifact without verifying the source repository it was built from.

Anti-patterns observed

  • Flagging a secret for revocation without a completion check.
  • Giving agent platforms owner-grade personal tokens instead of scoped service accounts.
  • Silently relaxing a security gate for shipping convenience.
8/10
Diagnostic complexity

The mechanism is a multi-step chain across three systems (public repo, Agent Platform, GitHub CI/release) with a corrected early hypothesis, hash-based attribution, and a lookalike-org deception; each step is simple, but reconstructing the full chain and its blast radius is not.

09 / Direct answers

Questions answered

What happened in the LiteLLM v1.107.0 supply-chain attack: unrevoked master key led to stolen GitHub tokens and a poisoned release incident?

On October 21, 2026, LiteLLM's release pipeline published a compromised litellm 1.107.0 containing compiled malware that steals credentials, built from an attacker-controlled fork, after a chain of credential thefts that began with an unrevoked master key exposed in May.

What was the root cause?

An exposed master key was identified for revocation but never revoked, and the Agent Platform it unlocked held an unscoped, person-owned GitHub CLI token; that combination turned a single leaked key into owner-level GitHub access, further token theft via CI, and a poisoned release once branch protection and the release gate were bypassed or relaxed.

How was the root cause discovered?

Checking request logs and audit-log token hashes, which moved the first-token theft from internal deployment logs to the Agent Platform API and corrected the early account. Matching the GH_TOKEN hash to the token that approved the production gate, which proved the October 10 exfiltration directly enabled the October 21 release. Recognizing that GitHub serves a fork's commits through the forked-from repository, so commit 20535d8f looked like it belonged to BerriAI/litellm while existing only on the Berri-AI fork. Realizing the relaxed release gate (any two engineers instead of a physical-device-locked account) let two stolen tokens trigger and approve the release.

What evidence mattered most?

The more-than-four-month-old exposure stayed live and became the attacker's entry point on October 10. That single response handed over the organization owner's GitHub CLI token. The hash matches proved the stolen CI secrets were the tokens that approved the release and deleted the run records.

Which assumptions were wrong?

Deleting a leaked file neutralizes the leak. The first stolen token came from internal deployment logs. Branch protection would hold against an attacker holding an owner token. A signed release from the normal pipeline must come from the real repository.

What delayed recovery?

The approved record describes restoration as follows: PyPI quarantined litellm 1.107.0 by 13:23 UTC and Docker images were removed or repointed by 14:20 UTC on October 21; registries were locked, org membership was reset to a single unaffected owner account, every token was treated as exfiltrated and revoked, and the canonical attack-chain report was published October 23 with process improvements promised the following week. It does not separately quantify a recovery delay unless stated in that account.

What should operators learn from this case?

Revocation is the fix for an exposed secret; deleting the file is not, and the revocation must be verified, not just flagged. Never give an automation platform a person-owned, unscoped token: use a scoped service account so one leak cannot become owner-level access. GitHub CLI OAuth tokens are post-2FA and skip sudo-mode reauthentication, so they deserve the same protection as owner credentials.

10 / Provenance

Original incident source

Public postmortemThe attack chain behind the v1.107.0 LiteLLM release →

Root Cause Casebook separates reported facts from analyst synthesis. This public record was explicitly approved before export.