DwmDns-0.1.0
Dwm::Dns::RRDataNSEC3PARAM Class Reference

Encapsulates NSEC3PARAM resource record data. More...

#include <DwmDnsRRDataNSEC3PARAM.hh>

Inheritance diagram for Dwm::Dns::RRDataNSEC3PARAM:
Collaboration diagram for Dwm::Dns::RRDataNSEC3PARAM:

Public Member Functions

 RRDataNSEC3PARAM ()
 Construct with an empty salt.
 
 RRDataNSEC3PARAM (uint8_t algorithm, uint8_t flags, uint16_t iterations, const std::string &salt)
 Construct with the given algorithm, flags, iterations and salt. More...
 
bool operator== (const RRDataNSEC3PARAM &nsec3param) const
 Equal-to operator, mostly for unit testing.
 
uint8_t Algorithm () const
 Returns the algorithm in the NSEC3PARAM resource record data.
 
uint8_t Algorithm (uint8_t algorithm)
 Sets and returns the algorithm in the NSEC3PARAM resource record data. More...
 
uint8_t Flags () const
 Returns the flags in the resource record data.
 
uint8_t Flags (uint8_t flags)
 Sets and returns the flags in the resource record data.
 
uint16_t Iterations () const
 Returns the iterations in the resource record data.
 
uint16_t Iterations (uint16_t iterations)
 Sets and returns the iterations in the resource record data.
 
const std::string & Salt () const
 Returns the salt in the resource record data.
 
const std::string & Salt (const std::string &salt)
 Sets and returns the salt in the resource record data.
 
uint8_t * Encode (uint8_t *pkt, uint8_t *ptr, uint16_t pktlen, LabelPositions &lps) const
 Encodes the NSEC3PARAM resource record data into buffer @ pkt of length pktlen, starting at ptr. More...
 
const uint8_t * Decode (const uint8_t *pkt, const uint8_t *ptr, uint16_t pktlen, uint16_t rdlen)
 Decodes the NSEC3PARAM resource record data from buffer pkt of length pktlen, starting at ptr. More...
 

Static Public Attributes

static const uint16_t k_rrtype = 51
 

Friends

std::ostream & operator<< (std::ostream &os, const RRDataNSEC3PARAM &param)
 Print the NSEC3PARAM resource record data to an ostream in human readable form. More...
 

Detailed Description

Encapsulates NSEC3PARAM resource record data.

See RFC5155 for more details.

Constructor & Destructor Documentation

◆ RRDataNSEC3PARAM()

Dwm::Dns::RRDataNSEC3PARAM::RRDataNSEC3PARAM ( uint8_t  algorithm,
uint8_t  flags,
uint16_t  iterations,
const std::string &  salt 
)

Construct with the given algorithm, flags, iterations and salt.

Member Function Documentation

◆ Algorithm()

uint8_t Dwm::Dns::RRDataNSEC3PARAM::Algorithm ( uint8_t  algorithm)

Sets and returns the algorithm in the NSEC3PARAM resource record data.

◆ Decode()

const uint8_t* Dwm::Dns::RRDataNSEC3PARAM::Decode ( const uint8_t *  pkt,
const uint8_t *  ptr,
uint16_t  pktlen,
uint16_t  rdlen 
)
virtual

Decodes the NSEC3PARAM resource record data from buffer pkt of length pktlen, starting at ptr.

Returns the address immediately following the encoded NSEC3PARAM resource record data in pkt on success. Throws std::out_of_range if pkt was too short to contain an encoded NSEC3PARAM resource record data.

Implements Dwm::Dns::RRData.

◆ Encode()

uint8_t* Dwm::Dns::RRDataNSEC3PARAM::Encode ( uint8_t *  pkt,
uint8_t *  ptr,
uint16_t  pktlen,
LabelPositions lps 
) const
virtual

Encodes the NSEC3PARAM resource record data into buffer @ pkt of length pktlen, starting at ptr.

Returns the address immediately following the encoded NSEC3PARAM resource record data in pkt on success. Throws std::out_of_range if pkt is too short to contain the encoded NSEC3PARAM resource record data.

Implements Dwm::Dns::RRData.

Friends And Related Function Documentation

◆ operator<<

std::ostream& operator<< ( std::ostream &  os,
const RRDataNSEC3PARAM param 
)
friend

Print the NSEC3PARAM resource record data to an ostream in human readable form.


The documentation for this class was generated from the following file: