DNS lookups through a pluggable Sovite.DNS.Resolver.
Summary
Types
A resolver module and the options passed to it on every lookup.
Functions
Returns the default resolver: Sovite.DNS.InetRes with no options.
Looks up records of type for name with the given resolver.
Looks up records and whether DNSSEC authenticated them. Resolvers
without Sovite.DNS.Resolver.lookup_secure/3 never authenticate.
Returns whether resolver validates DNSSEC, by asking for the root
zone's NS records, which are signed: a validating resolver that is
trusted authenticates them. DANE (RFC 7672) needs one.
Types
Functions
@spec default_resolver() :: resolver()
Returns the default resolver: Sovite.DNS.InetRes with no options.
@spec lookup(resolver(), String.t(), Sovite.DNS.Resolver.record_type()) :: {:ok, [Sovite.DNS.Resolver.record_data()]} | {:error, Sovite.DNS.Resolver.error()}
Looks up records of type for name with the given resolver.
See Sovite.DNS.Resolver for the data each record type returns.
@spec lookup_secure(resolver(), String.t(), Sovite.DNS.Resolver.record_type()) :: {:ok, [Sovite.DNS.Resolver.record_data()], boolean()} | {:error, Sovite.DNS.Resolver.error()}
Looks up records and whether DNSSEC authenticated them. Resolvers
without Sovite.DNS.Resolver.lookup_secure/3 never authenticate.
@spec validating?(resolver()) :: {:ok, boolean()} | {:error, Sovite.DNS.Resolver.error()}
Returns whether resolver validates DNSSEC, by asking for the root
zone's NS records, which are signed: a validating resolver that is
trusted authenticates them. DANE (RFC 7672) needs one.