dns_resolver::forwarding

Function resolve_forwarding

Source
pub async fn resolve_forwarding<'a>(
    context: &mut ForwardingContext<'a>,
    question: &Question,
) -> Result<ResolvedRecord, ResolutionError>
Expand description

Forwarding DNS resolution.

Attempts to resolve a query locally and, if it cannot, calls out to another nameserver and returns its response. As this other nameserver can spoof any records it wants, very little validation is done of its responses.

This has a 60s timeout.

ยงErrors

See ResolutionError.