Package org.xbill.DNS

Class CERTRecord

java.lang.Object
org.xbill.DNS.Record
org.xbill.DNS.CERTRecord
All Implemented Interfaces:
Serializable, Cloneable, Comparable<Record>

public class CERTRecord extends Record
Certificate Record - Stores a certificate associated with a name. The certificate might also be associated with a KEYRecord.
See Also:
  • Field Details

    • PKIX

      public static final int PKIX
      PKIX (X.509v3)
      See Also:
    • SPKI

      public static final int SPKI
      Simple Public Key Infrastructure
      See Also:
    • PGP

      public static final int PGP
      Pretty Good Privacy
      See Also:
    • URI

      public static final int URI
      Certificate format defined by URI
      See Also:
    • OID

      public static final int OID
      Certificate format defined by IOD
      See Also:
    • certType

      private int certType
    • keyTag

      private int keyTag
    • alg

      private int alg
    • cert

      private byte[] cert
  • Constructor Details

    • CERTRecord

      CERTRecord()
    • CERTRecord

      public CERTRecord(Name name, int dclass, long ttl, int certType, int keyTag, int alg, byte[] cert)
      Creates a CERT Record from the given data
      Parameters:
      certType - The type of certificate (see constants)
      keyTag - The ID of the associated KEYRecord, if present
      alg - The algorithm of the associated KEYRecord, if present
      cert - Binary data representing the certificate
  • Method Details

    • rrFromWire

      protected void rrFromWire(DNSInput in) throws IOException
      Description copied from class: Record
      Converts the type-specific RR to wire format - must be overridden
      Specified by:
      rrFromWire in class Record
      Throws:
      IOException
    • rdataFromString

      protected void rdataFromString(Tokenizer st, Name origin) throws IOException
      Description copied from class: Record
      Converts the text format of an RR to the internal format - must be overriden
      Specified by:
      rdataFromString in class Record
      Throws:
      IOException
    • rrToString

      protected String rrToString()
      Converts rdata to a String
      Specified by:
      rrToString in class Record
    • getCertType

      public int getCertType()
      Returns the type of certificate
    • getKeyTag

      public int getKeyTag()
      Returns the ID of the associated KEYRecord, if present
    • getAlgorithm

      public int getAlgorithm()
      Returns the algorithm of the associated KEYRecord, if present
    • getCert

      public byte[] getCert()
      Returns the binary representation of the certificate
    • rrToWire

      protected void rrToWire(DNSOutput out, Compression c, boolean canonical)
      Description copied from class: Record
      Converts the type-specific RR to wire format - must be overridden.
      Specified by:
      rrToWire in class Record