public class DSextends DelegatingDnssecRR
DNS DS (Delegation Signer) record payload for DNSSEC.
Contains the hash of a DNSKEY record used to authenticate delegated DNS zones in DNSSEC chain of trust.
See Also:
  • Constructor Details

    • DS

      public DS(int keyTag, byte algorithm, byte digestType, byte[] digest)
      Create a DS record, keeping the signature and digest algorithms as raw numbers for use when MiniDNS does not recognize them.
      Parameters:
      keyTag - the key tag of the DNSKEY RR that validates this delegation's signature
      algorithm - the wire signature algorithm byte
      digestType - the wire digest algorithm byte
      digest - the DNSKEY digest, which must not be null
    • DS

      public DS(int keyTag, DnssecConstants.SignatureAlgorithm algorithm, byte digestType, byte[] digest)
      Create a DS record with a known signature algorithm but a digest type that is kept as a raw number.
      Parameters:
      keyTag - the key tag of the DNSKEY RR that validates this delegation's signature
      algorithm - the signing algorithm, resolved from its wire value
      digestType - the wire digest algorithm byte
      digest - the DNSKEY digest, which must not be null
    • DS

      public DS(int keyTag, DnssecConstants.SignatureAlgorithm algorithm, DnssecConstants.DigestAlgorithm digestType, byte[] digest)
      Create a DS record with both the signature and the digest algorithm resolved to the constants MiniDNS knows.
      Parameters:
      keyTag - the key tag of the DNSKEY RR that validates this delegation's signature
      algorithm - the signing algorithm, resolved from its wire value
      digestType - the hashing algorithm the DNSKEY was digested with
      digest - the DNSKEY digest, which must not be null
  • Method Details

    • parse

      public static DS parse(DataInputStream dis, int length) throws IOException
      Read a DS record payload from a wire-format stream.
      Parameters:
      dis - the stream positioned at the start of the record payload
      length - the length in bytes of the record payload
      Returns:
      the parsed DS record
      Throws:
      IOException - if the payload cannot be read from the stream
    • getType

      public Record.TYPE getType()
      Report the RR type constant that identifies this payload as a DS record.
      Specified by:
      getType in class Data
      Returns:
      The DNS record type of this payload.