Official Crawl4AI Cloud: a hosted web scraping, extraction, and search API for AI agents. Free API key, 1,000 credits a month, no card. Fully open source: this repo is the Apache-2.0 crawler that powers it, and you can self-host it.
Python aiai-agentscrawl4ai-cloudcrawlerdata-extractionllmmarkdownmcpopen-sourceplaywrightpythonragscraperweb-crawlerweb-crawlingweb-scraping
docs: 0.8.7 release notes, changelog, README highlights; finalize security credits (q1uf3ng confirmed, Velayutham Selvaraj)
unclecode30187e6dc7c2
diff --git a/CHANGELOG.md b/CHANGELOG.mdindex 433160eb..d1e47249 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -5,6 +5,66 @@ All notable changes to Crawl4AI will be documented in this file.The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).+## [0.8.7] - 2026-06-01++0.8.7 is a security-hardening release. It bundles every responsibly-disclosed vulnerability patched since 0.8.6, plus the new DomainMapper feature and a batch of scraping, deep-crawl, and LLM fixes.++### Security++This release fixes multiple critical vulnerabilities in the Docker API server. If you self-host the Docker API, upgrade immediately. Two GitHub Security Advisories accompany this release.++- **CRITICAL: AST Sandbox Escape leading to Pre-Auth RCE (CVSS 9.8, CWE-94/913)**: a `gi_frame.f_back` frame-chain escape in the computed-field `eval()` path. Removed `eval()` from computed fields entirely and deleted `_safe_eval_expression`. Credit: Song Binglin ([q1uf3ng](https://github.com/q1uf3ng)).+- **CRITICAL: Hook Sandbox Escape RCE (CVSS 9.8, CWE-94)**: injected module objects (`asyncio`, `json`, `re`) carried a full `__builtins__`, bypassing the `__import__` block. Stripped injected builtins and removed dangerous allowlist entries. Credit: by111 ([August829](https://github.com/August829)).+- **CRITICAL: Hardcoded JWT Secret (CVSS 9.8, CWE-798)**: the default signing key `"mysecret"` allowed token forgery. Removed the default, reject weak/short secrets, and auto-generate an ephemeral key when JWT is enabled with no key set. Credit: by111 ([August829](https://github.com/August829)).+- **HIGH: Arbitrary File Write via `output_path` (CVSS 9.1, CWE-22)**: `/screenshot` and `/pdf` wrote to any path. Restricted writes to `CRAWL4AI_OUTPUT_DIR` and reject `..` traversal. Credit: Jeongbean Jeon, wulonchia.+- **HIGH: SSRF via Webhook URL (CVSS 8.6, CWE-918)**: webhook URLs on `/crawl/job` and `/llm/job` could reach internal and cloud-metadata IPs. Added a blocklist and `follow_redirects=False`. Credit: Jeongbean Jeon.+- **HIGH: SSRF via Direct Crawl Endpoints (CVSS 8.6, CWE-918)**: `/crawl`, `/md`, and `/llm` fetched arbitrary URLs, and IPv6-mapped IPv4 addresses (`[::ffff:169.254.169.254]`) bypassed naive checks. Added destination validation on all entry points and normalize IPv6-mapped IPv4 before the blocklist check. Credit: secsys_codex, Velayutham Selvaraj, IcySun.+- **HIGH: Arbitrary JavaScript Execution via `/execute_js` (CVSS 8.1, CWE-94)**: disabled by default via `CRAWL4AI_EXECUTE_JS_ENABLED`, removed `--disable-web-security` from default browser args, and added an SSRF blocklist on the destination. Credit: by111 ([August829](https://github.com/August829)).+- **MEDIUM: Monitor Endpoint Auth Bypass (CVSS 6.5, CWE-306)**: `/monitor/*` routes, including destructive actions, were unauthenticated. Added `token_dep` to the router and an explicit token check on the WebSocket endpoint. Credit: Jeongbean Jeon.+- **MEDIUM: Stored XSS in Monitor Dashboard (CVSS 6.1, CWE-79)**: URLs and errors were rendered via `innerHTML` without escaping. Added server-side `html.escape()` and a client-side `escapeHtml()` wrapper. Credit: Jeongbean Jeon.+- **eval() removed from `/config/dump`**: replaced with JSON input validated by Pydantic.+- **Config hardening**: validate the `markdown_generator` type in `CrawlerRunConfig` to reject malformed JSON (#1880).++### Added++- **DomainMapper**: comprehensive domain URL discovery, with an `include_subdomains` flag and a per-source timeout.+- **arun_many config-list support in the Docker API**: per-URL configs (#1837).+- **Docker server can listen on all addresses.**++### Fixed++- **Markdown and scraping fidelity**:+ - Preserve mermaid diagram text from SVGs and prevent nested fences (#1043)+ - Preserve table `rowspan`/`colspan` in cleaned HTML (#1920)+ - Preserve `.tail` text when removing empty elements (#1938)+ - Keep sentence order in `NlpSentenceChunking` (#1909)+- **Deep crawl and dispatcher**:+ - Fix the deep-crawl streaming ContextVar bug, using `set(False)` instead of `reset(token)` (#1917)+ - Wire `semaphore_count` into the auto-created `MemoryAdaptiveDispatcher` and default it to 10 (#1927)+- **LLM and providers**:+ - Add Bedrock to the provider prefixes so AWS credential auth works+ - Default `LLMExtractionStrategy.extraction_type` to schema+ - Add `LLMTableExtraction` to the Docker deserialization allowlist+- **Crawler and downloads**:+ - Return `success=True` for binary downloads and skip the block check when `downloaded_files` is set+ - Honor `<base href>` in prefetch `quick_extract_links` (#752)+- **Logging and MCP**:+ - Route `AsyncLogger` output to stderr by default (#1968) and use `Console(width=200)` for non-TTY contexts+ - Use `ensure_ascii=False` in the MCP bridge to preserve CJK characters (#1967)+- **Browser and misc**:+ - `browser_adapter` now uses the `Stealth` import, fixing a stealth import mismatch (#1960)+ - Correct the `arun()` return type to `CrawlResultContainer` (#1898)+ - Log the real failure reason before COMPLETE, fixing a misleading "SCRAPE ok" line (#1949)+ - Assistant toolbar scroll fix and issue-1973 fix++### Docs++- Added Privacy Policy, Terms of Service, and Support pages.++### Security Credits++Song Binglin (q1uf3ng), by111 (August829), Jeongbean Jeon, wulonchia, secsys_codex, Velayutham Selvaraj, and IcySun. See `SECURITY-CREDITS.md`.+## [0.8.0] - 2026-01-12### Securitydiff --git a/README.md b/README.mdindex 5c7c79b5..9f7835b1 100644--- a/README.md+++ b/README.md@@ -37,11 +37,11 @@ Limited slots._Crawl4AI turns the web into clean, LLM ready Markdown for RAG, agents, and data pipelines. Fast, controllable, battle tested by a 50k+ star community.-[✨ Check out latest update v0.8.6](#-recent-updates)+[✨ Check out latest update v0.8.7](#-recent-updates)-✨ **New in v0.8.6**: Security hotfix — replaced `litellm` with `unclecode-litellm` due to a PyPI supply chain compromise. If you're on v0.8.5, please upgrade immediately.+✨ **New in v0.8.7**: Security-hardening release. Fixes critical Docker API vulnerabilities (RCE, SSRF, auth bypass, file write, XSS, hardcoded JWT secret), adds DomainMapper, and ships scraping, deep-crawl, and LLM fixes. If you self-host the Docker API, upgrade immediately. [Release notes →](https://github.com/unclecode/crawl4ai/blob/main/docs/blog/release-v0.8.7.md)-✨ Recent v0.8.5: Anti-Bot Detection, Shadow DOM & 60+ Bug Fixes! Automatic 3-tier anti-bot detection with proxy escalation, Shadow DOM flattening, deep crawl cancellation, config defaults API, consent popup removal, and critical security patches. [Release notes →](https://github.com/unclecode/crawl4ai/blob/main/docs/blog/release-v0.8.5.md)+✨ Recent v0.8.6: Security hotfix that replaced `litellm` with `unclecode-litellm` due to a PyPI supply chain compromise.✨ Previous v0.8.0: Crash Recovery & Prefetch Mode! Deep crawl crash recovery with `resume_state` and `on_state_change` callbacks for long-running crawls. New `prefetch=True` mode for 5-10x faster URL discovery. [Release notes →](https://github.com/unclecode/crawl4ai/blob/main/docs/blog/release-v0.8.0.md)@@ -565,7 +565,20 @@ async def test_news_crawl():## ✨ Recent Updates<details open>-<summary><strong>Version 0.8.6 — Security Hotfix: litellm Supply Chain Fix</strong></summary>+<summary><strong>Version 0.8.7 Release Highlights - Security Hardening, DomainMapper & Community Fixes</strong></summary>++A security-hardening release. Fixes critical Docker API vulnerabilities (AST sandbox escape RCE, hook sandbox RCE, hardcoded JWT secret, SSRF on webhook and crawl endpoints, arbitrary file write, monitor auth bypass, stored XSS, and unauthenticated JS execution), adds the DomainMapper feature, and ships a batch of scraping, deep-crawl, and LLM fixes. If you self-host the Docker API, upgrade immediately.++```bash+pip install -U crawl4ai+```++[Full v0.8.7 Release Notes →](https://github.com/unclecode/crawl4ai/blob/main/docs/blog/release-v0.8.7.md)++</details>++<details>+<summary><strong>Version 0.8.6 - Security Hotfix: litellm Supply Chain Fix</strong></summary>Replaced `litellm` dependency with `unclecode-litellm` due to a PyPI supply chain compromise affecting the original package. If you're on v0.8.5 or earlier, upgrade immediately.diff --git a/SECURITY-CREDITS.md b/SECURITY-CREDITS.mdindex 84c9fd59..5caea7f2 100644--- a/SECURITY-CREDITS.md+++ b/SECURITY-CREDITS.md@@ -9,5 +9,5 @@ We thank the following security researchers for their responsible disclosure:| wulonchia | [email protected] | File write via output_path (independent report) | 2026-04-13 || by111 (August829) | GitHub: [August829](https://github.com/August829) | Hardcoded JWT secret, eval in /config/dump, /execute_js, hook sandbox escape | 2026-04-14 || secsys_codex | [email protected] | SSRF via /md, /crawl, /llm endpoints (URL destination validation) | 2026-04-18 |-| Velayutham S | [email protected] | SSRF via missing host validation in validate_url_scheme (independent report) | 2026-05-06 |+| Velayutham Selvaraj | [LinkedIn](https://www.linkedin.com/in/velayuthamselvaraj) | SSRF via missing host validation in validate_url_scheme (independent report) | 2026-05-06 || IcySun | [email protected] | SSRF, file write via output_path, missing auth by default, hook sandbox bypass via asyncio (independent report) | 2026-05-15 |diff --git a/docs/blog/release-v0.8.7.md b/docs/blog/release-v0.8.7.mdnew file mode 100644index 00000000..ed75b860--- /dev/null+++ b/docs/blog/release-v0.8.7.md@@ -0,0 +1,113 @@+# Crawl4AI v0.8.7: Security Hardening, DomainMapper & Community Fixes++*June 2026 - 7 min read*++---++I'm releasing Crawl4AI v0.8.7, a security-hardening release. It bundles every responsibly-disclosed vulnerability we patched since v0.8.6, adds the new DomainMapper feature, and ships a batch of scraping, deep-crawl, and LLM fixes from our team and the community.++If you self-host the Docker API server, please upgrade right away. This release closes several critical issues, and two GitHub Security Advisories accompany it.++## What's New at a Glance++- **Security hardening**: critical RCE, SSRF, auth-bypass, file-write, XSS, and hardcoded-secret fixes across the Docker API+- **DomainMapper**: comprehensive domain URL discovery with subdomain and per-source timeout controls+- **arun_many config-list in the Docker API**: send per-URL configs in one request+- **Markdown fidelity fixes**: mermaid SVG text, table rowspan/colspan, trailing text, sentence order+- **Deep crawl and dispatcher fixes**: streaming ContextVar bug, semaphore wiring+- **LLM and provider fixes**: Bedrock auth, schema-first extraction, table-extraction allowlist+- **Logging and MCP fixes**: stderr by default, non-TTY width, CJK preservation++---++## Security++v0.8.7 is, first and foremost, a security release. Every issue below was reported responsibly by the community, and every reporter is credited in `SECURITY-CREDITS.md` and the published advisories.++### Remote Code Execution++- **AST sandbox escape (CVSS 9.8)**: a `gi_frame.f_back` frame-chain walk escaped the computed-field expression sandbox to reach the real `__import__`. We removed `eval()` from computed fields entirely. SDK users can still pass Python callables via the `function` key.+- **Hook sandbox escape (CVSS 9.8)**: injected module objects (`asyncio`, `json`, `re`) carried a full `__builtins__`, providing an alternate path to `__import__`. We stripped those builtins and tightened the allowlist.++### Authentication and Secrets++- **Hardcoded JWT secret (CVSS 9.8)**: the signing key defaulted to `"mysecret"`. We removed the default, reject weak or short secrets at startup, and auto-generate an ephemeral key when JWT is enabled with no key set.+- **Monitor endpoint auth bypass (CVSS 6.5)**: the `/monitor/*` routes, including destructive actions, ran without auth. They now require a token, and the WebSocket endpoint checks the token explicitly.++### SSRF++- **Webhook SSRF (CVSS 8.6)**: webhook URLs on `/crawl/job` and `/llm/job` could hit internal and cloud-metadata addresses. We added a blocklist and disabled redirect following.+- **Direct crawl-endpoint SSRF (CVSS 8.6)**: `/crawl`, `/md`, and `/llm` fetched arbitrary URLs, and IPv6-mapped IPv4 addresses such as `[::ffff:169.254.169.254]` slipped past naive checks. We added destination validation on all entry points and normalize IPv6-mapped IPv4 before the blocklist check.++### File Write, XSS, and JS Execution++- **Arbitrary file write (CVSS 9.1)**: `/screenshot` and `/pdf` honored any `output_path`. Writes are now restricted to `CRAWL4AI_OUTPUT_DIR`, and `..` traversal is rejected.+- **Stored XSS in the monitor dashboard (CVSS 6.1)**: crawled URLs were rendered via `innerHTML` without escaping. We escape on both the server and the client now.+- **Arbitrary JS execution via `/execute_js` (CVSS 8.1)**: the endpoint is disabled by default behind `CRAWL4AI_EXECUTE_JS_ENABLED`, we removed `--disable-web-security` from default browser args, and added an SSRF blocklist on the destination.++We also replaced the `eval()` in `/config/dump` with Pydantic-validated JSON input, and added type validation for `markdown_generator` in `CrawlerRunConfig`.++---++## New Features++### DomainMapper++DomainMapper discovers URLs across an entire domain in one pass, combining multiple discovery sources. It supports an `include_subdomains` flag to widen or narrow the crawl boundary, and a per-source timeout so a single slow source cannot stall the whole map. See the [Domain Mapping guide](../core/domain-mapping.md).++### arun_many config-list in the Docker API++The Docker API now accepts a list of configs aligned with the list of URLs, so you can apply a different `CrawlerRunConfig` to each URL in a single `arun_many` request (#1837).++---++## Fixes++**Markdown and scraping**++- Preserve mermaid diagram text rendered as SVG, and prevent nested code fences (#1043)+- Preserve table `rowspan` and `colspan` in cleaned HTML (#1920)+- Preserve `.tail` text when removing empty elements (#1938)+- Keep sentence order in `NlpSentenceChunking` (#1909)++**Deep crawl and dispatcher**++- Fix the deep-crawl streaming ContextVar bug by using `set(False)` instead of `reset(token)` (#1917)+- Wire `semaphore_count` into the auto-created `MemoryAdaptiveDispatcher` and default it to 10 (#1927)++**LLM and providers**++- Add Bedrock to the provider prefixes so AWS credential auth works+- Default `LLMExtractionStrategy.extraction_type` to schema+- Add `LLMTableExtraction` to the Docker deserialization allowlist++**Crawler and downloads**++- Return `success=True` for binary downloads, and skip the block check when `downloaded_files` is set+- Honor `<base href>` in prefetch `quick_extract_links` (#752)++**Logging and MCP**++- Route `AsyncLogger` output to stderr by default (#1968) and use `Console(width=200)` for non-TTY contexts+- Use `ensure_ascii=False` in the MCP bridge to preserve CJK characters (#1967)++**Browser and misc**++- `browser_adapter` now uses the `Stealth` import, fixing a stealth import mismatch (#1960)+- Correct the `arun()` return type to `CrawlResultContainer` (#1898)+- Log the real failure reason before COMPLETE, fixing a misleading success line (#1949)+- Assistant toolbar scroll fix and issue-1973 fix++---++## Upgrade++```bash+pip install -U crawl4ai+```++Docker users should pull the latest image once the Docker release workflow finishes.++## Security Credits++Thank you to the researchers who disclosed these issues responsibly: Song Binglin (q1uf3ng), by111 (August829), Jeongbean Jeon, wulonchia, secsys_codex, Velayutham Selvaraj, and IcySun. Full details are in `SECURITY-CREDITS.md`.