Skip to content

dns_stub

Structs

  • DnsStubInput - Lib-level input for [execute_dns_stub]. The CLI layer builds this

Functions


Struct

Lib-level input for [execute_dns_stub]. The CLI layer builds this from its clap-derived args struct.

Fields:

  • listen: std::net::SocketAddr - UDP/TCP DNS listen address reachable by the sandboxed agent process.

Trait Implementations:

  • Debug
    • fn fmt(self: &Self, f: & mut $crate::fmt::Formatter) -> $crate::fmt::Result
  • Clone
    • fn clone(self: &Self) -> DnsStubInput

Function

Run the internal sandbox-local DNS stub.

The stub provides an explicit resolver endpoint for structurally confined bwrap sandboxes. It refuses all queries deterministically instead of forwarding to the host ambient resolver.

Returns an error if UDP or TCP DNS listeners cannot bind.

fn execute_dns_stub(args: &DnsStubInput) -> Result<i32, crate::error::RunError>