zeroclaw-labs/zeroclaw · error
Host '{host}' is not in {tool_name}.allowed_domains
Error message
Host '{host}' is not in {tool_name}.allowed_domains What it means
Error "Host '{host}' is not in {tool_name}.allowed_domains" thrown in zeroclaw-labs/zeroclaw.
Source
Thrown at crates/zeroclaw-tools/src/web_fetch.rs:762
To allow this host, add it (or \"*\") to \
{tool_name}.allowed_private_hosts in config.toml"
);
}
if private_explicit || (private_tolerated && host_is_private_or_local) {
::zeroclaw_log::record!(
WARN,
::zeroclaw_log::Event::new(module_path!(), ::zeroclaw_log::Action::Note)
.with_outcome(::zeroclaw_log::EventOutcome::Unknown)
.with_attrs(::serde_json::json!({"tool_name": tool_name, "host": host})),
"web_fetch: allowing host via allowed_private_hosts"
);
}
let skip_allowed_domains = host_is_private_or_local && private_tolerated;
if !skip_allowed_domains && !domain_guard::host_matches_allowlist(&host, allowed_domains) {
anyhow::bail!("Host '{host}' is not in {tool_name}.allowed_domains");
}
// Private opt-in relaxes only the public-address requirement. DNS still
// resolves and the metadata exclusion remains unconditional.
validate_dns(&host, private_tolerated)?;
Ok(url.to_string())
}
fn append_chunk_with_cap(buffer: &mut Vec<u8>, chunk: &[u8], hard_cap: usize) -> bool {
if buffer.len() >= hard_cap {
return true;
}
let remaining = hard_cap - buffer.len();
if chunk.len() > remaining {
buffer.extend_from_slice(&chunk[..remaining]);
return true;View on GitHub (pinned to 88bb9c8533)
Solutions
- Add the host to the tool's allowed_domains list in the configuration, e.g. `zeroclaw config set tools.web_fetch.allowed_domains '["example.com"]'`.
- Remove the allowed_domains restriction only if you trust arbitrary fetches, or fetch the URL through an already-allowed proxy host.
When it happens
Trigger: Thrown at crates/zeroclaw-tools/src/web_fetch.rs:762 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of zeroclaw-labs/zeroclaw@88bb9c8533 (2026-08-23).
Data as JSON: /api/errors/b5293d95d88e6977.
Report an issue: GitHub.