CLI command
probierz evaluate dns
Say whether a product's domain holds the DNS records the internet reads: its addresses, mail exchange, SPF and DMARC policies, the certificate authorities it allows.
Invocation#
probierz evaluate dns --app <APP_ID>Required inputs and options#
<APP_ID>is the product, asprobierz apps listnames it. Its manifest declaresdns: {resolver: <address>:<port>, records: [{name: <domain>, type: <A, AAAA, CNAME, MX, NS, TXT or CAA>, contains: <text one value must hold>}]};resolveris the firstnameserverof /etc/resolv.conf when omitted, andcontainsmay be left out when the record only has to exist.
Output and state effects#
Asks the name server for each record over UDP (over TCP when the answer was too long for UDP), as any resolver asks, and prints JSON: appId, resolver, records (each with its name, type, contains, values written as zone files write them, for example 10 mail.shop.example or 0 issue "letsencrypt.org", the server's rcode and verdict: found when a value holds contains, differs when values came and none holds it, missing when none came, the name lacking such a record or being NXDOMAIN) and pass, true when every record is found. A result that does not pass exits 1 after it is printed.
Exact refusals#
dns-undeclared(probierz.dns, exit 1): the manifest has nodnssection, names no record, a record without a name, a type the check does not ask, acontainsthat is no text, or a resolver that is no address and port, and none in /etc/resolv.conf; no name server is asked.dns-unanswered(exit 69): the name server did not answer within 5 seconds, answered with something that is no DNS reply, or answered that it failed (SERVFAIL, REFUSED), naming the record asked; no record is judged. Real test: tests/dns/records.rs (the test product's own name server for shop.test, with and without its DMARC record).
Declared refusals#
What probierz refusals list declares for this command at revision d2cd6156e8b8dc6204dab7b46ec0b34b2bb03cea (probierz 0.1.7 (revision unknown, not built from a git checkout)): each cause's id, the operation declaring it, its exit status and code, and its remedy.
dns-undeclared(probierz.dns, exit 1, config): reading which DNS records {app} holds: {problem}. declare in the product's manifestdns: {records: [{name: <domain>, type: <A, AAAA, CNAME, MX, NS, TXT or CAA>, contains: <text one value must hold>}]}, andresolver: <address>:<port>when /etc/resolv.conf names none.dns-unanswered(probierz.dns, exit 69, infra_down): asking {resolver} for {record}: {problem}. check that this machine reaches the name server dns.resolver (or /etc/resolv.conf) names and that it answers for the domain, then ask again.
Source snapshot#
Generated from the Rust binaries at revision 99a74945a3598a8d73b6c6cbe5aae4f283becea3 of Probierz's private source repository.
Combined help SHA-256: 77529678a61237f774b59e76df0d1907cb749ef5da56d2ed913b040793b7d30b; binary SHA-256: be9e0eaff0e6ea50403a0c6f6d467697a4eac676f9523b8dc13a596d2b5526c5.