Read the docs
TI-2026-66844 Aliases GHSA-f989-c77f-r2cq

Crawl4AI: LLM credential exfiltration in Docker server via request base_url and env: token resolution

Priority LOW 38CWE-200Published · Updated

Key facts

Attack vector
—
Privileges required
—
User interaction
—
Attack complexity
—
Impact type
Information disclosure
Confidentiality · integrity · availability
—
Fix status
Fixed

No CVSS vector from any source. Fix status from GitHub. Impact type from CWE-200.

Summary

### Summary The Docker API server let a request control where LLM calls were sent and which environment variable an LLM token resolved from. Both could be abused to exfiltrate server-held secrets. The Docker API is unauthenticated by default. ### Vector 1 - attacker base_url `/md`, `/llm`, and `/llm/job` accepted a `base_url` in the request and used it as the LLM endpoint while still attaching the server's configured provider API key. An attacker set `base_url` to a server they control and received the provider key (and any provider keys the server holds) in the inbound request. ### Vector 2 - arbitrary environment variable read via `env:` `LLMConfig(api_token="env:NAME")` resolved `NAME` from the server environment with `os.getenv`. Because request bodies were deserialized into `LLMConfig` (via a crawler config / extraction strategy), an attacker could set `api_token="env:SECRET_KEY"` (or `env:REDIS_PASSWORD`, etc.) and, paired with an attacker `base_url`, exfiltrate that secret. Reading the server's `SECRET_KEY` enables forging authentication tokens. ### Impact Disclosure of LLM provider API keys and other server secrets to an attacker-controlled endpoint; reading the JWT `SECRET_KEY` can lead to authentication bypass. ### Fix - The LLM endpoints ignore a request-supplied `base_url`; the endpoint is always derived server-side from the provider name. The field is still accepted but no longer honored (no breaking 4xx). - `LLMConfig` refuses `env:` resolution of protected environment-variable names (names containing SECRET/PASSWORD/PRIVATE, prefixes CRAWL4AI*/AWS_SECRET*, and SECRET_KEY/REDIS_PASSWORD/TOKEN). Normal provider keys (e.g. OPENAI_API_KEY) are unaffected. ### Workarounds - Upgrade to the patched version. - Enable authentication (`CRAWL4AI_API_TOKEN`). - Do not place sensitive secrets in the server environment alongside provider keys. ### Credits - Geo ([geo-chen](https://github.com/geo-chen)) - reported the LLM credential exfiltration via request base_url. - Internal security audit (Crawl4AI maintainers) - the env: arbitrary-variable read.

Why it matters now

Fix Fixed crawl4ai (PyPI): 0.8.8

SSVC decision points

Not available: CISA has not published SSVC decision points for this record.

Affected products

VendorProductAffected versionsFixed inStatusSource
—crawl4ai (PyPI)before 0.8.80.8.8Patch availableGHSA-f989-c77f-r2cq
  • crawl4ai (PyPI) Vendor— Affected before 0.8.8 Fixed in 0.8.8 Patch available GHSA-f989-c77f-r2cq

Remediation

  • Fix · GHSA-f989-c77f-r2cq crawl4ai (PyPI) Fixed in 0.8.8 Advisory →

Timeline

  1. 2026-10-03 Threatist record created from GHSA-f989-c77f-r2cq

References

Sources

This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences