Hunt: LiteLLM 1.107.0 startup-hook backdoor: cook.pth, sitecustomize.py, /tmp lock files and calls to litellm[.]dev
Update Oct 25: Microsoft published Defender XDR advanced hunting queries (connections to www.litellm[.]dev, the six startup-file SHA-256 hashes, OpenSSL runs using .pc_e_ staging dirs, and an inline Python query against the LiteLLM_CredentialsTable/LiteLLM_ProxyModelTable tables) plus the marker file /tmp/.pc_once_72129118c59f5636c0bb, written after a successful upload. Investigate from a clean machine: running python or pip in the affected environment can set off the collector. On the GitHub side, LiteLLM's root-cause analysis lists IPs 69.48.229.143 and 199.91.221.39, the lookalike org Berri-AI, and branches named like ci-tmp-* whose workflows posted secrets to webhook.site. If your org was forked by or interacted with these, check your own audit log.
For the LiteLLM 1.107.0 compromise:
- Files: any
site-packages/cook.pth,cook.pyor an unexpectedsitecustomize.py(plus their__pycache__copies), in venvs, containers and CI caches.cook.pthcontains onlyimport cook. - Markers:
/tmp/.pc_once_72129118c59f5636c0bb,/tmp/remote_code_loader.lock,/tmp/.pc_sq_*,/tmp/.pc_e_*. - Processes: detached Python processes started via
setsidwith working directory/, or holding the loader lock. - Network: DNS or proxy hits for
www.litellm[.]dev/litellm[.]dev(POST/healthcheck, headerX-Token: XWiA8gZNa7NcX2XRoAEb, old IE user agent), hourly requests toraw.githubusercontent[.]com/letters9813/pythonclient-test/main/domain.txt, thenhttp://<domain>/codepy. Also look for reads of169.254.169.254from Python on hosts that shouldn't need it. - CI: any runner job that installed litellm 1.107.0 or ran its image: StepSecurity notes the stealer reads
/proc/<pid>/environof every process, so treat every secret in that job as stolen.
Clean up with tools that don't start the affected interpreter, preserve proxy/DNS/EDR and cloud audit logs first, then rotate.
Sources: Microsoft Security Blog: Inside the LiteLLM 1.107.0 supply chain compromise (Oct 23) · LiteLLM: The attack chain behind the v1.107.0 LiteLLM release (root-cause analysis, Oct 23) · JFrog research · AISLE research · StepSecurity research