Skip to main content

Module interceptor

Module interceptor 

Source
Expand description

DNS query interception, filtering, and resolution.

The DnsInterceptor bridges the smoltcp UDP socket (bound to gateway:53) and the host DNS resolvers. Queries are read from the socket, checked against the domain block list, forwarded to hickory-resolver for resolution, and responses are sent back through the socket.

Because resolution is async and the poll loop is sync, queries are sent to a background tokio task via a channel. Responses come back through another channel and are written to the smoltcp socket on the next poll iteration.

Structsยง

DnsInterceptor
DNS query/response interceptor.