Skip to main content

shared_http_source_client

Function shared_http_source_client 

Source
pub fn shared_http_source_client() -> Result<Arc<Client>, SourceError>
Expand description

Return the process-wide HTTP client used by source resolution.

The first call constructs the client; subsequent calls return the same Arc<reqwest::Client>. The client is wired to the default_egress_policy via a custom DNS resolver so a Sigma rule that points the daemon at a cloud metadata endpoint cannot exfiltrate IAM credentials.

Errors building the client are surfaced as SourceError rather than panicking so callers can fail-soft on broken TLS setups instead of crashing the daemon.