CVE-2024-9606 Improper Output Neutralization for Logs in berriai/litellm
Attackers can read sensitive API keys from logs because the masking logic only hides the first five characters of the key.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2024-9606?
CVE-2024-9606 is a high-severity vulnerability in berriai/litellm, published on 20 Mar 2025. An attacker can exploit it over the internet without logging in, with no action from the victim.
Official description
In berriai/litellm before version 1.44.12, the `litellm/litellm_core_utils/litellm_logging.py` file contains a vulnerability where the API key masking code only masks the first 5 characters of the key. This results in the leakage of almost the entire API key in the logs, exposing a significant amount of the secret key. The issue affects version v1.44.9.
Which versions are affected by CVE-2024-9606?
3 open source packages ship an affected version, including litellm. It affects 1 product.
| Package | Affected | Fixed in |
|---|---|---|
litellm PyPI | All versions | 1.44.12 |
litellm PyPI | All versions | 1.44.12 |
litellm PyPI | All versions | 1.44.12 |
Products include Litellm Litellm.
How do I fix CVE-2024-9606?
Upgrade litellm to 1.44.12 or later.
Is CVE-2024-9606 being exploited?
It is not confirmed as exploited in the wild, but public exploit code for CVE-2024-9606 exists.
Other vulnerabilities in berriai/litellm
Sources
Also known as GHSA-g5pg-73fc-hjwq, PYSEC-2026-1548.