Security Alert: Compromised Python Package – litellm
Dear NSCC Users,
We wish to inform you that two malicious versions of the Python package litellm (v1.82.7 or v1.82.8) was found on PyPI.
These tampered versions contained hidden code that runs automatically every time Python starts without needing to import the package. The malicious code was heavily obfuscated and designed to steal sensitive data, including environment variables, SSH keys, and cloud credentials, and transmit them to an attacker-controlled server.
Full details from the LiteLLM developer: https://docs.litellm.ai/blog/security-update-march-2026
Am I Affected?
You are likely affected if you performed any of the following actions between 24 March 2026 18:39 SGT and 25 March 2026 00:00 SGT:
- Manual Install: Installed or upgraded litellm via pip.
- Unpinned Versions: Ran `pip install litellm` which was not pinned to a specific version, resulting in the download of v1.82.7 or v1.82.8
- Docker Builds: Built a Docker image during this window using `pip install litellm`.
- Transitive Dependency: Used AI frameworks (e.g., CrewAI, LangChain, or MCP servers) that automatically pulled in litellm as a sub-dependency.
Immediate Actions Required:
- Verify Installed Versions
- Run the following command in your terminal or environment:
pip show litellm
or
pip list | grep litellm
- If you have v1.82.7 or v1.82.8 installed, proceed to the next step.
- Run the following command in your terminal or environment:
- Remove or Downgrade
- Uninstall the compromised version:
pip uninstall litellm
- To resume your work safely, downgrade to a safe version:
pip install litellm==1.82.6
- Uninstall the compromised version:
- Rotate Your Credentials
- If you were running an affected version, assume all secrets in that environment are compromised.
- Rotate any environment variables, SSH keys, API keys, and cloud credentials accessible from that environment.
Should you have any questions or need assistance, please contact our Helpdesk via the Service Desk Portal or email us at[email protected].
Thank you.
Warm regards,
The NSCC Team

