Package org.xbill.DNS
Class NSEC3PARAMRecord
java.lang.Object
org.xbill.DNS.Record
org.xbill.DNS.NSEC3PARAMRecord
- All Implemented Interfaces:
Serializable
,Cloneable
,Comparable<Record>
Next SECure name 3 Parameters - this record contains the parameters (hash algorithm, salt,
iterations) used for a valid, complete NSEC3 chain present in a zone. Zones signed using NSEC3
must include this record at the zone apex to inform authoritative servers that NSEC3 is being
used with the given parameters.
- Author:
- Brian Wellington, David Blacka
- See Also:
-
Field Summary
-
Constructor Summary
ConstructorsConstructorDescriptionNSEC3PARAMRecord
(Name name, int dclass, long ttl, int hashAlg, int flags, int iterations, byte[] salt) Creates an NSEC3PARAM record from the given data. -
Method Summary
Modifier and TypeMethodDescriptionint
getFlags()
Returns the flagsint
Returns the hash algorithmint
Returns the number of iterationsbyte[]
getSalt()
Returns the saltbyte[]
Hashes a name with the parameters of this NSEC3PARAM record.protected void
rdataFromString
(Tokenizer st, Name origin) Converts the text format of an RR to the internal format - must be overridenprotected void
rrFromWire
(DNSInput in) Converts the type-specific RR to wire format - must be overriddenprotected String
Converts rdata to a Stringprotected void
rrToWire
(DNSOutput out, Compression c, boolean canonical) Converts the type-specific RR to wire format - must be overridden.Methods inherited from class org.xbill.DNS.Record
byteArrayFromString, byteArrayToString, compareTo, equals, fromString, fromString, fromWire, getAdditionalName, getDClass, getName, getRRsetType, getTTL, getType, hashCode, newRecord, newRecord, newRecord, newRecord, rdataToString, rdataToWireCanonical, sameRRset, sameRRset, toString, toWire, toWireCanonical, unknownToString, withName
-
Constructor Details
-
NSEC3PARAMRecord
public NSEC3PARAMRecord(Name name, int dclass, long ttl, int hashAlg, int flags, int iterations, byte[] salt) Creates an NSEC3PARAM record from the given data.- Parameters:
name
- The ownername of the NSEC3PARAM record (generally the zone name).dclass
- The class.ttl
- The TTL.hashAlg
- The hash algorithm.flags
- The value of the flags field.iterations
- The number of hash iterations.salt
- The salt to use (may be null).
-
-
Method Details
-
rrFromWire
Description copied from class:Record
Converts the type-specific RR to wire format - must be overridden- Specified by:
rrFromWire
in classRecord
- Throws:
IOException
-
rrToWire
Description copied from class:Record
Converts the type-specific RR to wire format - must be overridden. -
rdataFromString
Description copied from class:Record
Converts the text format of an RR to the internal format - must be overriden- Specified by:
rdataFromString
in classRecord
- Throws:
IOException
-
rrToString
Converts rdata to a String- Specified by:
rrToString
in classRecord
-
getHashAlgorithm
public int getHashAlgorithm()Returns the hash algorithm -
getFlags
public int getFlags()Returns the flags -
getIterations
public int getIterations()Returns the number of iterations -
getSalt
public byte[] getSalt()Returns the salt -
hashName
Hashes a name with the parameters of this NSEC3PARAM record.- Parameters:
name
- The name to hash- Returns:
- The hashed version of the name
- Throws:
NoSuchAlgorithmException
- The hash algorithm is unknown.
-