Package org.xbill.DNS

Class ExtendedErrorCodeOption

java.lang.Object
org.xbill.DNS.EDNSOption
org.xbill.DNS.ExtendedErrorCodeOption

public class ExtendedErrorCodeOption extends EDNSOption
EDNS option to provide additional information about the cause of DNS errors (RFC 8914).
Since:
3.4
  • Nested Class Summary

    Nested classes/interfaces inherited from class org.xbill.DNS.EDNSOption

    EDNSOption.Code
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final int
    The server is unable to respond to the request because the domain is on a blocklist due to an internal security policy imposed by the operator of the server resolving or forwarding the query.
    static final int
    The resolver is returning the Rcode.SERVFAIL from its cache.
    static final int
    The server is unable to respond to the request because the domain is on a blocklist due to an external requirement imposed by an entity other than the operator of the server resolving or forwarding the query.
    static final int
    A DSRecord existed at a parent, but no supported matching DNSKEYRecord could be found for the child.
    static final int
    The resolver attempted to perform DNSSEC validation, but validation ended in the Bogus state.
    static final int
    The resolver attempted to perform DNSSEC validation, but validation ended in the Indeterminate state.
    static final int
    The server is unable to respond to the request because the domain is on a blocklist as requested by the client.
    static final int
    For policy reasons (legal obligation or malware filtering, for instance), an answer was forged.
    static final int
    The authoritative server cannot answer with data for a zone it is otherwise configured to support.
    static final int
    An unrecoverable error occurred while communicating with another server.
    static final int
    The resolver could not reach any of the authoritative name servers (or they potentially refused to reply).
    static final int
    The resolver attempted to perform DNSSEC validation, but no Zone Key Bit was set in a DNSKEY.
    static final int
    Response to a query with the Recursion Desired (RD) bit clear, or when the server is not configured for recursion (and the query is for a domain for which it is not authoritative).
    static final int
    The server is unable to answer the query, as it was not fully functional when the query was received.
    static final int
    The requested operation or query is not supported.
    static final int
    The resolver attempted to perform DNSSEC validation, but the requested data was missing and a covering NSECRecord or NSEC3Record was not provided
    static final int
    The error in question falls into a category that does not match known extended error codes.
    static final int
    An authoritative server or recursive resolver that receives a query from an "unauthorized" client can annotate its Rcode.REFUSED message with this code.
    static final int
    The resolver attempted to perform DNSSEC validation, but no RRSIGRecords could be found for at least one RRset where RRSIGRecords were expected.
    static final int
    The resolver attempted to perform DNSSEC validation, but no signatures are presently valid and some (often all) are expired.
    static final int
    The signature expired before it started to become valid.
    static final int
    The resolver attempted to perform DNSSEC validation, but no signatures are presently valid and at least some are not yet valid.
    static final int
    The resolver was unable to resolve the answer within its time limits and decided to answer with previously cached data instead of answering with an error.
    static final int
    The resolver was unable to resolve an answer within its configured time limits and decided to answer with a previously cached Rcode.NXDOMAIN answer instead of answering with an error.
    static final int
    Result synthesized from aggressive NSEC cache.
    static final int
    DNS over QUIC session resumption error.
    static final int
    Unable to conform to policy.
    static final int
    The resolver attempted to perform DNSSEC validation, but a DNSKEYRecord RRset contained only unsupported DNSSEC algorithms.
    static final int
    The resolver attempted to perform DNSSEC validation, but a DSRecord RRset contained only unsupported Digest Types.
    static final int
    The NSEC3 iterations value is not supported.
  • Constructor Summary

    Constructors
    Constructor
    Description
    ExtendedErrorCodeOption(int errorCode)
    Creates an extended error code EDNS option.
    ExtendedErrorCodeOption(int errorCode, String text)
    Creates an extended error code EDNS option.
  • Method Summary

    Modifier and Type
    Method
    Description
    static int
    code(String text)
    Gets the numeric value corresponding to an EDE text mnemonic.
    int
     
     
    static String
    text(int code)
    Gets the text mnemonic corresponding to an EDE value.

    Methods inherited from class org.xbill.DNS.EDNSOption

    equals, fromWire, getCode, hashCode, toString, toWire

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Field Details

    • OTHER

      public static final int OTHER
      The error in question falls into a category that does not match known extended error codes.
      See Also:
    • UNSUPPORTED_DNSKEY_ALGORITHM

      public static final int UNSUPPORTED_DNSKEY_ALGORITHM
      The resolver attempted to perform DNSSEC validation, but a DNSKEYRecord RRset contained only unsupported DNSSEC algorithms.
      See Also:
    • UNSUPPORTED_DS_DIGEST_TYPE

      public static final int UNSUPPORTED_DS_DIGEST_TYPE
      The resolver attempted to perform DNSSEC validation, but a DSRecord RRset contained only unsupported Digest Types.
      See Also:
    • STALE_ANSWER

      public static final int STALE_ANSWER
      The resolver was unable to resolve the answer within its time limits and decided to answer with previously cached data instead of answering with an error.
      See Also:
    • FORGED_ANSWER

      public static final int FORGED_ANSWER
      For policy reasons (legal obligation or malware filtering, for instance), an answer was forged.
      See Also:
    • DNSSEC_INDETERMINATE

      public static final int DNSSEC_INDETERMINATE
      The resolver attempted to perform DNSSEC validation, but validation ended in the Indeterminate state.
      See Also:
    • DNSSEC_BOGUS

      public static final int DNSSEC_BOGUS
      The resolver attempted to perform DNSSEC validation, but validation ended in the Bogus state.
      See Also:
    • SIGNATURE_EXPIRED

      public static final int SIGNATURE_EXPIRED
      The resolver attempted to perform DNSSEC validation, but no signatures are presently valid and some (often all) are expired.
      See Also:
    • SIGNATURE_NOT_YET_VALID

      public static final int SIGNATURE_NOT_YET_VALID
      The resolver attempted to perform DNSSEC validation, but no signatures are presently valid and at least some are not yet valid.
      See Also:
    • DNSKEY_MISSING

      public static final int DNSKEY_MISSING
      A DSRecord existed at a parent, but no supported matching DNSKEYRecord could be found for the child.
      See Also:
    • RRSIGS_MISSING

      public static final int RRSIGS_MISSING
      The resolver attempted to perform DNSSEC validation, but no RRSIGRecords could be found for at least one RRset where RRSIGRecords were expected.
      See Also:
    • NO_ZONE_KEY_BIT_SET

      public static final int NO_ZONE_KEY_BIT_SET
      The resolver attempted to perform DNSSEC validation, but no Zone Key Bit was set in a DNSKEY.
      See Also:
    • NSEC_MISSING

      public static final int NSEC_MISSING
      The resolver attempted to perform DNSSEC validation, but the requested data was missing and a covering NSECRecord or NSEC3Record was not provided
      See Also:
    • CACHED_ERROR

      public static final int CACHED_ERROR
      The resolver is returning the Rcode.SERVFAIL from its cache.
      See Also:
    • NOT_READY

      public static final int NOT_READY
      The server is unable to answer the query, as it was not fully functional when the query was received.
      See Also:
    • BLOCKED

      public static final int BLOCKED
      The server is unable to respond to the request because the domain is on a blocklist due to an internal security policy imposed by the operator of the server resolving or forwarding the query.
      See Also:
    • CENSORED

      public static final int CENSORED
      The server is unable to respond to the request because the domain is on a blocklist due to an external requirement imposed by an entity other than the operator of the server resolving or forwarding the query.
      See Also:
    • FILTERED

      public static final int FILTERED
      The server is unable to respond to the request because the domain is on a blocklist as requested by the client.
      See Also:
    • PROHIBITED

      public static final int PROHIBITED
      An authoritative server or recursive resolver that receives a query from an "unauthorized" client can annotate its Rcode.REFUSED message with this code.
      See Also:
    • STALE_NXDOMAIN_ANSWER

      public static final int STALE_NXDOMAIN_ANSWER
      The resolver was unable to resolve an answer within its configured time limits and decided to answer with a previously cached Rcode.NXDOMAIN answer instead of answering with an error.
      See Also:
    • NOT_AUTHORITATIVE

      public static final int NOT_AUTHORITATIVE
      Response to a query with the Recursion Desired (RD) bit clear, or when the server is not configured for recursion (and the query is for a domain for which it is not authoritative).
      See Also:
    • NOT_SUPPORTED

      public static final int NOT_SUPPORTED
      The requested operation or query is not supported.
      See Also:
    • NO_REACHABLE_AUTHORITY

      public static final int NO_REACHABLE_AUTHORITY
      The resolver could not reach any of the authoritative name servers (or they potentially refused to reply).
      See Also:
    • NETWORK_ERROR

      public static final int NETWORK_ERROR
      An unrecoverable error occurred while communicating with another server.
      See Also:
    • INVALID_DATA

      public static final int INVALID_DATA
      The authoritative server cannot answer with data for a zone it is otherwise configured to support.
      See Also:
    • SIGNATURE_EXPIRED_BEFORE_VALID

      public static final int SIGNATURE_EXPIRED_BEFORE_VALID
      The signature expired before it started to become valid.
      Since:
      3.6
      See Also:
    • TOO_EARLY

      public static final int TOO_EARLY
      DNS over QUIC session resumption error.
      Since:
      3.6
      See Also:
    • UNSUPPORTED_NSEC3_ITERATIONS_VALUE

      public static final int UNSUPPORTED_NSEC3_ITERATIONS_VALUE
      The NSEC3 iterations value is not supported.
      Since:
      3.6
      See Also:
    • UNABLE_TO_CONFORM_TO_POLICY

      public static final int UNABLE_TO_CONFORM_TO_POLICY
      Unable to conform to policy.
      Since:
      3.6
      See Also:
    • SYNTHESIZED

      public static final int SYNTHESIZED
      Result synthesized from aggressive NSEC cache.
      Since:
      3.6
      See Also:
  • Constructor Details

    • ExtendedErrorCodeOption

      public ExtendedErrorCodeOption(int errorCode, String text)
      Creates an extended error code EDNS option.
      Parameters:
      errorCode - the extended error.
      text - optional error message intended for human readers.
    • ExtendedErrorCodeOption

      public ExtendedErrorCodeOption(int errorCode)
      Creates an extended error code EDNS option.
      Parameters:
      errorCode - the extended error.
  • Method Details

    • text

      public static String text(int code)
      Gets the text mnemonic corresponding to an EDE value.
      Since:
      3.5
    • code

      public static int code(String text)
      Gets the numeric value corresponding to an EDE text mnemonic.
      Since:
      3.5
    • getErrorCode

      public int getErrorCode()
    • getText

      public String getText()