OpenClaw versions prior to 2026.3.1 contain a server-side request forgery vulnerability in web_search citation redirect resolution that uses a private-network-allowing SSRF policy. An attacker who can influence citation redirect targets can trigger internal-network requests from the OpenClaw host to loopback, private, or internal destinations.
How AI Introduced This
Yes. The initial Gemini grounding feature that introduced `resolveRedirectUrl()` and sent HEAD requests to citation URLs was commit `3a3c2da9168f93397eeb3109d521819e10dc44fd`, which is explicitly co-authored by Claude Opus 4.6. A later human-only commit (`5eb72ab769517e31d96140f1aa66bd1a47a40c2a`) kept that code path exploitable by moving it onto the SSRF guard while explicitly opting into `dangerouslyAllowPrivateNetwork` for attacker-controlled redirect targets.
▶Attribution Chain
▶Bug-Introducing Commits(4)
fix: use structured readResponseText result in Gemini error path
Extracted from squash merge 3a3c2da
▶9 other sub-commits in this PR
feat: add Gemini (Google Search grounding) as web_search provider
feat: auto-detect search provider from available API keys
fix: merge __testing exports, downgrade auto-detect log to debug
fix: use defaultRuntime.log instead of .debug (not in RuntimeEnv type)
fix: mark gemini apiKey as sensitive in zod schema
fix: address Greptile review — add externalContent to Gemini payload, add Gemini/Grok entries to schema labels/help, rem...
fix(web-search): add JSON parse guard for Gemini API responses
style: fix import order and formatting after rebase onto main
Web search: send Gemini API key via header
Deep Verification
by investigator-overrideYes. The initial Gemini grounding feature that introduced `resolveRedirectUrl()` and sent HEAD requests to citation URLs was commit `3a3c2da9168f93397eeb3109d521819e10dc44fd`, which is explicitly co-authored by Claude Opus 4.6. A later human-only commit (`5eb72ab769517e31d96140f1aa66bd1a47a40c2a`) kept that code path exploitable by moving it onto the SSRF guard while explicitly opting into `dangerouslyAllowPrivateNetwork` for attacker-controlled redirect targets.
▶AI Signals(4)
| Claude Code | Co-author trailer | Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> | 95% |
| Claude Code | Co-author trailer | Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> | 95% |
| Claude Code | Co-author trailer | Co-Authored-By: Claude <noreply@anthropic.com> | 95% |
| Claude Code | Co-author trailer | Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> | 95% |