Forcepoint X-Labs ने 18 मई को LiteLLM पर एक supply-chain attack disclose किया, LiteLLM वो open-source Python gateway है जो 100+ LLM providers के लिए unified interface के रूप में काम करता है। Threat group TeamPCP ने PyPI releases 1.82.7 और 1.82.8 को poison किया। Attack chain ने LiteLLM के source repository को directly breach नहीं किया — इसके बजाय, TeamPCP ने Trivy (वो vulnerability scanner जो LiteLLM अपनी build pipeline में use करता है) को poison किया Trivy maintainers को impersonate करके और automated release processes trigger करके ताकि backdoored Trivy binaries distribute हों। जब LiteLLM के CI/CD ने compromised Trivy build pull किया, backdoor ने runner की memory को scrape किया और एक PYPI_PUBLISH token exfiltrate किया। Attackers ने फिर उस token को use किया malicious LiteLLM releases directly publish करने के लिए। Forcepoint X-Labs के Prashant Kumar ने disclose किया।
Payload behavior दोनों versions में अलग है। Version 1.82.7 ने proxy_server.py के अंदर Base64-encoded payloads use किए जो proxy startup पर execute होते थे — जो भी file diff करे उसे आसानी से spot होता। Version 1.82.8 ज़्यादा stealthy थी: इसने site-packages में एक litelllm_init.pth file deploy की जो "Python interpreter startup पर हर subsequent process में activate होती है, चाहे LiteLLM कभी explicitly imported हुआ हो या नहीं।" यह key escalation है — एक बार install होने पर, backdoor उस environment में जब भी कोई Python interpreter start होता है तब चलता है, सिर्फ़ LiteLLM use होने पर नहीं। Targeted credentials: OpenAI, Anthropic, Microsoft Azure API keys; AWS, Google Cloud, और Azure SDK credentials; user home directories से kubeconfig और AWS credential files। Exfiltration AES-256-CBC encrypted थी 32-byte session key के साथ, curl के through models.litellm.cloud पर भेजी गई। Sysmon.py नाम का एक persistence module हर 50 minutes पर checkmarx.zone को नए instructions के लिए poll करता था।
Architectural lesson trust-chain hijack है। TeamPCP ने well-defended LiteLLM repository पर attack नहीं किया; उन्होंने Trivy पर attack किया, जिस पर LiteLLM की build process by default trust करती थी। यह वही class का supply-chain attack है जो xz-utils (वो maintainer impersonation जिसने systemd को लगभग compromise कर दिया था) और इस साल के शुरू में का npm tj-actions attack। आपकी build process में कोई भी tool — scanners, formatters, dependency resolvers, linters — एक potential attack surface है, भले ही उसका actual job security adjacent हो। LiteLLM compromise especially damaging है क्योंकि LiteLLM की पूरी value proposition हर major LLM provider के लिए gateway होना है। जैसा Prashant Kumar ने कहा: "LiteLLM major AI providers के लिए unified gateway के रूप में functions करता है, मतलब एक compromise ने attackers को OpenAI, Anthropic और Azure credentials का simultaneous access दिया।" अगर आपने 1.82.7 या 1.82.8 install की, environment ने जो भी provider credential touch की वो potentially TeamPCP के हाथों में है।
सोमवार: अगर आपके पास कोई भी environment है जिसने LiteLLM 1.82.7 या 1.82.8 चलाई, environment के access वाली हर API key को compromised treat करो — OpenAI, Anthropic, Azure, AWS, GCP keys तुरंत rotate करो, और unfamiliar requests के लिए usage logs audit करो। अपनी site-packages में litelllm_init.pth file और Sysmon.py persistence module check करो। अपनी network layer पर models.litellm.cloud और checkmarx.zone के लिए egress block करो जब तक host clean न हो जाए। आगे के लिए अपनी build pipeline के लिए: Trivy और हर दूसरी build-tool dependency को verified hashes (सिर्फ़ versions नहीं) पर pin करो, security-adjacent tooling के लिए signed releases require करो, और PyPI publish tokens को isolate करो ताकि वो build-time scanners को accessible न हों। Forcepoint के writeup ने exact timeline, download counts, या BerriAI की response disclose नहीं की — वो gaps exposure को precisely estimate करना impossible बनाते हैं। Worst-case की तरह treat करो जब तक BerriAI एक coordinated disclosure publish न करे।
