Class DNSKEY

java.lang.Object
org.minidns.record.Data
org.minidns.record.DNSKEY

public class DNSKEY extends Data
DNSKEY record payload.
  • Field Details

  • Constructor Details

    • DNSKEY

      public DNSKEY(short flags, byte protocol, byte algorithm, byte[] key)
    • DNSKEY

      public DNSKEY(short flags, byte protocol, DnssecConstants.SignatureAlgorithm algorithm, byte[] key)
  • Method Details

    • parse

      public static DNSKEY parse(DataInputStream dis, int length) throws IOException
      Throws:
      IOException
    • getType

      public Record.TYPE getType()
      Description copied from class: Data
      The payload type.
      Specified by:
      getType in class Data
      Returns:
      The payload type.
    • getKeyTag

      public int getKeyTag()
      Retrieve the key tag identifying this DNSKEY. The key tag is used within the DS and RRSIG record to distinguish multiple keys for the same name. This implementation is based on the reference implementation shown in RFC 4034 Appendix B.
      Returns:
      this DNSKEY's key tag
    • serialize

      public void serialize(DataOutputStream dos) throws IOException
      Description copied from class: Data
      The internal method used to serialize Data subclasses.
      Specified by:
      serialize in class Data
      Parameters:
      dos - the output stream to serialize to.
      Throws:
      IOException - if an I/O error occurs.
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • getKeyLength

      public int getKeyLength()
    • getKey

      public byte[] getKey()
    • getKeyAsDataInputStream

      public DataInputStream getKeyAsDataInputStream()
    • getKeyBase64

      public String getKeyBase64()
    • getKeyBigInteger

      public BigInteger getKeyBigInteger()
    • keyEquals

      public boolean keyEquals(byte[] otherKey)
    • isSecureEntryPoint

      public boolean isSecureEntryPoint()