Class DnsRDataCaa
java.lang.Object
org.pcap4j.packet.DnsRDataCaa
- All Implemented Interfaces:
Serializable, DnsResourceRecord.DnsRData
DNS CAA RDATA
+0-1-2-3-4-5-6-7-|0-1-2-3-4-5-6-7-| | Flags | Tag Length = n | +----------------+----------------+...+---------------+ | Tag char 0 | Tag char 1 |...| Tag char n-1 | +----------------+----------------+...+---------------+ +----------------+----------------+.....+----------------+ | Value byte 0 | Value byte 1 |.....| Value byte m-1 | +----------------+----------------+.....+----------------+ (m = d - n - 2) where d is the length of the RDATA section.) where: Flags: One octet containing bit flags for record. See rfc for details. Bit 0, Issuer Critical Flag All other bit positions are reserved for future use. Tag: The property identifier, a sequence of US-ASCII characters. Value: A sequence of octets representing the property value.
- Since:
- pcap4j 1.7.2
- See Also:
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateDnsRDataCaa(byte[] rawData, int offset, int length) privateDnsRDataCaa(DnsRDataCaa.Builder builder) -
Method Summary
Modifier and TypeMethodDescriptionbooleanbyte[]bytegetTag()getValue()inthashCode()booleanintlength()static DnsRDataCaanewInstance(byte[] rawData, int offset, int length) A static factory method.toString()
-
Field Details
-
CAA_RR_MIN_LEN
private static final int CAA_RR_MIN_LEN- See Also:
-
serialVersionUID
private static final long serialVersionUIDA serial UID for serialization.- See Also:
-
critical
private final boolean critical -
reservedFlags
private final byte reservedFlags -
tag
-
value
-
-
Constructor Details
-
DnsRDataCaa
- Throws:
IllegalRawDataException
-
DnsRDataCaa
-
-
Method Details
-
newInstance
public static DnsRDataCaa newInstance(byte[] rawData, int offset, int length) throws IllegalRawDataException A static factory method. This method validates the arguments byByteArrays.validateBounds(byte[], int, int), which may throw exceptions undocumented here.- Parameters:
rawData- rawDataoffset- offsetlength- length- Returns:
- a new DnsRDataCaa object.
- Throws:
IllegalRawDataException- if parsing the raw data fails.
-
isCritical
public boolean isCritical()- Returns:
- true if the Issuer Critical Flag is set to 1; false otherwise.
-
getReservedFlags
public byte getReservedFlags()- Returns:
- reservedFlags (Bit 1 to 7 of the Flags field)
-
getTag
- Returns:
- tag
-
getValue
- Returns:
- value
-
length
public int length()- Specified by:
lengthin interfaceDnsResourceRecord.DnsRData- Returns:
- length
-
getRawData
public byte[] getRawData()- Specified by:
getRawDatain interfaceDnsResourceRecord.DnsRData- Returns:
- raw data
-
getBuilder
- Returns:
- a new Builder object populated with this object's fields.
-
toString
- Specified by:
toStringin interfaceDnsResourceRecord.DnsRData- Parameters:
indent- indent- Returns:
- String representation of this object.
-
toString
-
toString
- Specified by:
toStringin interfaceDnsResourceRecord.DnsRData- Parameters:
indent- indentheaderRawData- the raw data of the DNS header including this RDATA.- Returns:
- String representation of this object.
-
equals
-
hashCode
-