GHSA-3h23-7824-pj8r
CRITICALGHSA-3h23-7824-pj8r is a critical-severity (CVSS 9.8) remote code execution vulnerability in archivebox. O3 Security confirms whether GHSA-3h23-7824-pj8r is actually reachable in your code before you act, and blocks exploitation at runtime until you patch.
ArchiveBox Vulnerable to RCE via unvalidated per-crawl config overrides in AddView
Real-World Exposure
archiveboxReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects PyPI packages — download data is not available via public APIs for these ecosystems.
Description
The /add/ endpoint (AddView in core/views.py) accepts a config JSON field that gets merged into the crawl config without validation. This config is exported as environment variables when archive plugins run, allowing injection of arbitrary tool arguments to achieve RCE.
When PUBLIC_ADD_VIEW=True (common for bookmarklet usage), this is exploitable without authentication. The endpoint is also @csrf_exempt.
Affected code:
core/views.py:887 - user config extracted with no validation: custom_config = form.cleaned_data.get("config") or {}
core/views.py:918 - merged into crawl config: config.update(custom_config)
config/configset.py:255-256 - crawl config applied with high priority: if crawl and hasattr(crawl, "config") and crawl.config: config.update(crawl.config)
hooks.py:398-411 - config exported as env vars: for key, value in config.items(): if key in SKIP_KEYS: continue env[key] = str(value)
plugins/ytdlp/on_Snapshot__02_ytdlp.bg.py:122-123 - env var args passed to yt-dlp: ytdlp_args_extra = get_env_array("YTDLP_ARGS_EXTRA", []) cmd.extend(ytdlp_args_extra)
PoC (pre-auth when PUBLIC_ADD_VIEW=True):
curl -X POST http://localhost:8000/add/
-d "url=https://www.youtube.com/watch?v=dQw4w9WgXcQ"
-d "depth=0"
-d "config={"YTDLP_ARGS_EXTRA": "[\"--exec\", \"id > /tmp/pwned\"]"}"
After the crawl runs, yt-dlp executes id > /tmp/pwned via its --exec flag.
Same approach works with GALLERYDL_ARGS_EXTRA (gallery-dl --exec), or overriding any *_BINARY key.
Impact: Remote code execution on the ArchiveBox server. Pre-auth when PUBLIC_ADD_VIEW=True.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 🐍PyPI | archivebox | all versions | No fix |
Detection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for archivebox. O3's reachability analysis confirms whether the vulnerable code path is actually invoked in your application, so you act on real exposure instead of every transitive match.
Remediation status
No patched version of archivebox has shipped for GHSA-3h23-7824-pj8r yet. Where your build allows, override or pin the dependency away from the vulnerable range, and apply any maintainer-recommended mitigation.
Mitigate without a patch
If you can't upgrade right away: gate or disable the affected feature, validate untrusted input at the boundary, and avoid passing attacker-controlled data into the vulnerable path. O3's runtime protection blocks exploitation in production as an interim safeguard until the upgrade lands.
How O3 protects you
O3 pinpoints whether GHSA-3h23-7824-pj8r is reachable in your code and exactly where to fix it, then blocks exploitation in production at runtime until the patched version is deployed.
Tailored to GHSA-3h23-7824-pj8r. Runtime protection reduces exposure until a permanent patch is applied and verified — it complements patching, it doesn't replace it.
Frequently Asked Questions
Is GHSA-3h23-7824-pj8r in your dependencies?
O3 detects GHSA-3h23-7824-pj8r across PyPI dependencies and uses function-level reachability to confirm whether the vulnerable code path is actually reachable — not just present. No false positives.