CVE-2026-53753: Crawl4AI: AST Sandbox Escape via gi_frame.f_back Chain - Pre-Auth RCE in Docker API

Published Jun 16, 2026
·
Updated

Summary

The safeevalexpression() function in the computed fields feature uses an AST validator that only blocks attributes starting with underscore. Python generator and frame object attributes (giframe, fback, fbuiltins) do NOT start with underscore, enabling a complete sandbox escape to achieve arbitrary code execution.

The attack requires no authentication (JWT disabled by default) and is triggered via POST /crawl with a crafted extraction schema.

Attack Vector

An attacker sends a POST /crawl request with a JsonCssExtractionStrategy schema containing a malicious computed field expression that: 1. Creates a generator to access giframe 2. Walks the frame chain via fback 3. Reaches fbuiltins containing the real import 4. Imports os and executes arbitrary commands

Impact

Unauthenticated remote code execution inside the Docker container. An attacker can execute arbitrary system commands, read/write files, and exfiltrate secrets.

Fix Details

1. Removed eval() from computed field expression path entirely -- expressions now log a warning and return default value 2. Deleted safeevalexpression() function and SAFEEVALBUILTINS (dead security-sensitive code) 3. function key with Python callables still works for SDK users 4. Replaced eval() in /config/dump with JSON-based input validated by Pydantic 5. Fixed hookmanager sandbox: stripped builtins, loader, spec from injected modules; removed getattr, setattr, type, buildclass from allowed builtins

Workarounds

1. Upgrade to the patched version (recommended) 2. Enable JWT authentication via CRAWL4AIAPITOKEN environment variable 3. Restrict network access to the Docker API

Credits

- Song Binglin (q1uf3ng) - reported the AST sandbox escape - by111 (August829) - reported the hook sandbox builtins escape and hardcoded JWT secret bypass - jannahopp - PR #1855 proposing eval removal - ntohidi - PR #1886 proposing allowlist approach

Other sources

Crawl4AI is an open-source LLM friendly web crawler & scraper. Prior to 0.8.7, the safeevalexpression() function in the computed fields feature uses an AST validator that only blocks attributes starting with underscore. Python generator and frame object attributes (giframe, fback, fbuiltins) do NOT start with underscore, enabling a complete sandbox escape to achieve arbitrary code execution. The attack requires no authentication (JWT disabled by default) and is triggered via POST /crawl with a crafted extraction schema. This vulnerability is fixed in 0.8.7.

MITRE

Affected Software

2 affected componentsFixes available
pip/crawl4ai<=0.8.6
0.8.7
Kidocode Crawl4ai<0.8.7

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade pip/crawl4ai to a version that resolves this vulnerability.

    Fixed in 0.8.7
  2. Upgrade

    Upgrade Crawl4AI to a version that resolves this vulnerability.

    Fixed in 0.8.7
  3. Compensating control

    Restrict network access to the Docker API so the service cannot reach the Docker API from untrusted networks/clients.

Event History

Jun 16, 2026
Advisory Published
via GitHub·08:13 PM
Data Sourced
via GitHub·08:13 PM
DescriptionSeverityWeaknessAffected Software
Jun 23, 2026
CVE Published
via MITRE·06:17 PM
Data Sourced
via MITRE·06:17 PM
DescriptionSeverityWeakness
Data Sourced
via NVD·07:17 PM
DescriptionSeverityWeaknessAffected Software
Mar 12, 58463
Event
via NVD·06:14 PM

Frequently Asked Questions

1

What is the severity of CVE-2026-53753?

The severity of CVE-2026-53753 is critical with a score of 9.8.

2

How do I fix CVE-2026-53753?

To fix CVE-2026-53753, update to the latest version of the crawl4ai software that addresses this vulnerability.

3

What type of vulnerability is CVE-2026-53753?

CVE-2026-53753 is classified as a code injection vulnerability.

4

What impact does CVE-2026-53753 have?

CVE-2026-53753 allows attackers to bypass the AST validator, potentially executing arbitrary code in a sandboxed environment.

5

Which software is affected by CVE-2026-53753?

CVE-2026-53753 affects the pip/crawl4ai software.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203