{"record":{"id":"b04a11f2011f7a6d","repo":"tinyhumansai/openhuman","slug":"host-host-not-in-browser-allowed-domains","errorCode":null,"errorMessage":"Host '{host}' not in browser.allowed_domains","messagePattern":"Host '(.+?)' not in browser\\.allowed_domains","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/openhuman/tools/impl/browser/browser.rs","lineNumber":315,"sourceCode":"            anyhow::bail!(\"Only http:// and https:// URLs are allowed\");\n        }\n\n        if self.allowed_domains.is_empty() && !allow_all_browser_domains() {\n            anyhow::bail!(\n                \"Browser tool enabled but no allowed_domains configured. \\\n                Add [browser].allowed_domains in config.toml or set OPENHUMAN_BROWSER_ALLOW_ALL=1\"\n            );\n        }\n\n        let host = extract_host(url)?;\n\n        if is_private_host(&host) {\n            anyhow::bail!(\"Blocked local/private host: {host}\");\n        }\n\n        if !self.allowed_domains.is_empty() && !host_matches_allowlist(&host, &self.allowed_domains)\n        {\n            anyhow::bail!(\"Host '{host}' not in browser.allowed_domains\");\n        }\n\n        Ok(())\n    }\n\n    /// Execute an agent-browser command\n    async fn run_command(&self, args: &[&str]) -> anyhow::Result<AgentBrowserResponse> {\n        let mut cmd = Command::new(\"agent-browser\");\n\n        // Add session if configured\n        if let Some(ref session) = self.session_name {\n            cmd.arg(\"--session\").arg(session);\n        }\n\n        // Add --json for machine-readable output\n        cmd.args(args).arg(\"--json\");\n\n        debug!(\"Running: agent-browser {} --json\", args.join(\" \"));","sourceCodeStart":297,"sourceCodeEnd":333,"githubUrl":"https://github.com/tinyhumansai/openhuman/blob/749120085864ce16e0f273c7b86fac7740b39c5b/src/openhuman/tools/impl/browser/browser.rs#L297-L333","documentation":"validate_url rejects a host that is not matched by the configured [browser].allowed_domains patterns (when the allowlist is non-empty). This is the domain-allowlist enforcement point for the automation backend.","triggerScenarios":"Thrown at src/openhuman/tools/impl/browser/browser.rs:315 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Add the host (or a matching wildcard pattern) to [browser].allowed_domains.","Navigate to a domain already on the allowlist."],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"749120085864ce16e0f273c7b86fac7740b39c5b","analyzedAt":"2026-08-17T21:21:45.363Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}