Code Injection Affecting litellm package, versions [,1.34.39)


Severity

Recommended
0.0
high
0
10

CVSS assessment made by Snyk's Security Team

    Threat Intelligence

    Exploit Maturity
    Proof of concept
    EPSS
    0.05% (20th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk ID SNYK-PYTHON-LITELLM-7231126
  • published 10 Jun 2024
  • disclosed 6 Jun 2024
  • credit mvlttt

How to fix?

Upgrade litellm to version 1.34.39 or higher.

Overview

litellm is a Library to easily interface with LLM API providers

Affected versions of this package are vulnerable to Code Injection due to the use of unvalidated input in the eval function within the secret management system. An attacker can execute arbitrary code by setting the UI_LOGO_PATH variable to a remote server address in the get_image function, leading to the writing of a malicious Google KMS configuration file to the cached_logo.jpg file. This file can then be used to execute arbitrary code by assigning malicious code to the SAVE_CONFIG_TO_DB environment variable, leading to full system control.

References

CVSS Scores

version 3.1
Expand this section

Snyk

Recommended
7.2 high
  • Attack Vector (AV)
    Network
  • Attack Complexity (AC)
    Low
  • Privileges Required (PR)
    High
  • User Interaction (UI)
    None
  • Scope (S)
    Unchanged
  • Confidentiality (C)
    High
  • Integrity (I)
    High
  • Availability (A)
    High
Expand this section

NVD

7.2 high