{"record":{"id":"70d7a2e244742fbc","repo":"owasp-amass/amass","slug":"no-record-of-this-type","errorCode":null,"errorMessage":"no record of this type","messagePattern":"no record of this type","errorType":"error_code","errorClass":"ErrNoRecordOfThisType","httpStatus":null,"severity":"info","filePath":"engine/plugins/support/resolvers.go","lineNumber":27,"sourceCode":"\t\"errors\"\n\t\"runtime\"\n\t\"strings\"\n\t\"time\"\n\n\t\"github.com/miekg/dns\"\n\t\"github.com/owasp-amass/resolve/conn\"\n\t\"github.com/owasp-amass/resolve/pool\"\n\t\"github.com/owasp-amass/resolve/selectors\"\n\t\"github.com/owasp-amass/resolve/servers\"\n\t\"github.com/owasp-amass/resolve/types\"\n\t\"github.com/owasp-amass/resolve/utils\"\n\t\"github.com/owasp-amass/resolve/wildcards\"\n\t\"golang.org/x/net/publicsuffix\"\n)\n\nvar (\n\tErrNameDoesNotExist     = errors.New(\"name does not exist\")\n\tErrNoRecordOfThisType   = errors.New(\"no record of this type\")\n\tErrFailedMaxDNSAttempts = errors.New(\"failed the maximum number of DNS attempts\")\n)\n\ntype baseline struct {\n\taddress string\n\tqps     int\n}\n\n// baselineResolvers is a list of trusted public DNS resolvers.\nvar baselineResolvers = []baseline{\n\t{\"8.8.8.8\", 5}, // Google Primary\n\t//\t{\"8.8.4.4\", 5},         // Google Secondary\n\t{\"95.85.95.85\", 2},     // Gcore DNS Primary\n\t{\"2.56.220.2\", 2},      // Gcore DNS Secondary\n\t{\"76.76.2.0\", 2},       // ControlD Primary\n\t{\"76.76.10.0\", 2},      // ControlD Secondary\n\t{\"9.9.9.9\", 2},         // Quad9 Primary\n\t{\"149.112.112.112\", 2}, // Quad9 Secondary","sourceCodeStart":9,"sourceCodeEnd":45,"githubUrl":"https://github.com/owasp-amass/amass/blob/79299dce87b0085db0f2f4ef3e9c52cccb49f514/engine/plugins/support/resolvers.go#L9-L45","documentation":"ErrNoRecordOfThisType is a sentinel error returned by dnsQuery/PerformQuery in engine/plugins/support/resolvers.go when the DNS response is successful (RcodeSuccess/NOERROR) but contains zero answer records of any kind. It means the name exists but has no records at all for the queried type, distinct from NXDOMAIN (ErrNameDoesNotExist). Callers use it to skip names that exist but lack the requested record type.","triggerScenarios":"Calling support.PerformQuery(ctx, name, qtype) where the response has Rcode == dns.RcodeSuccess but len(resp.Answer) == 0 — e.g. querying A records for a name that only exists as a CNAME edge case or has an empty answer from a trusted resolver.","commonSituations":"Querying TXT records for a domain that has none; asking for AAAA on IPv4-only hosts; DNS servers returning NOERROR with empty answers for non-existent record types; rate-limited or filtered resolvers returning empty NOERROR responses.","solutions":["Skip this record type for the name and try a different qtype (A vs AAAA vs TXT) if needed.","Do not retry aggressively: NOERROR-empty responses are often authoritative.","Compare with support.ErrNoRecordOfThisType via == / errors.Is to handle it separately from NXDOMAIN.","If records are expected, verify with dig @resolver name TYPE and try alternate trusted resolvers."],"exampleFix":"// before\nrr, err := support.PerformQuery(ctx, fqdn, dns.TypeAAAA)\nif err != nil {\n    return err\n}\n// after\nrr, err := support.PerformQuery(ctx, fqdn, dns.TypeAAAA)\nif err != nil {\n    if err == support.ErrNoRecordOfThisType {\n        return nil // name exists, just no AAAA records\n    }\n    return err\n}","handlingStrategy":"try-catch","validationCode":"// Pre-check other record types before assuming data is missing\ndig +short example.com A\ndig +short example.com TXT","typeGuard":"func isNoRecordOfThisType(err error) bool { return errors.Is(err, support.ErrNoRecordOfThisType) }","tryCatchPattern":"rr, err := support.PerformQuery(ctx, name, qtype)\nif err != nil {\n    if errors.Is(err, support.ErrNoRecordOfThisType) {\n        return nil // name exists, no records of this type\n    }\n    return err\n}","preventionTips":["Fall back to alternative qtypes (A/AAAA/TXT/CNAME) when one returns empty.","Treat NOERROR-empty as authoritative and avoid retry storms.","Keep this error distinct from ErrNameDoesNotExist in your handling logic.","Verify surprising empties with dig against a public resolver."],"tags":["dns","empty-answer","sentinel-error"],"backgroundTag":"empty-result-set","analyzedSha":"79299dce87b0085db0f2f4ef3e9c52cccb49f514","analyzedAt":"2026-09-06T08:22:48.198Z","contentChangedAt":"2026-09-06T08:22:48.198Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}