Encapsulates KEY resource record data. More...
#include <DwmDnsRRDataKEY.hh>


Public Member Functions | |
| RRDataKEY () | |
| Construct with an empty public key. | |
| RRDataKEY (uint16_t flags, uint8_t protocol, uint8_t algorithm, uint16_t moreFlags, const std::string &publicKey) | |
Construct with the given flags, protocol, algorithm, moreFlags and publicKey. More... | |
| bool | operator== (const RRDataKEY &key) const |
| Equal-to operator, mostly for unit testing. | |
| uint16_t | Flags () const |
| Returns the contained flags. | |
| uint16_t | Flags (uint16_t flags) |
| Sets and returns the contained flags. | |
| uint8_t | Protocol () const |
| Returns the contained protocol. | |
| uint8_t | Protocol (uint8_t protocol) |
| Sets and returns the contained protocol. | |
| uint8_t | Algorithm () const |
| Returns the contained algorithm. | |
| uint8_t | Algorithm (uint8_t algorithm) |
| Sets and returns the contained algorithm. | |
| uint16_t | MoreFlags () const |
| Returns the contained 'more flags'. | |
| uint16_t | MoreFlags (uint16_t moreFlags) |
| Sets and returns the contained 'more flags'. | |
| const std::string & | PublicKey () const |
| Returns the contained public key. | |
| const std::string & | PublicKey (const std::string &publicKey) |
| Sets and returns the contained public key. | |
| uint8_t * | Encode (uint8_t *pkt, uint8_t *ptr, uint16_t pktlen, LabelPositions &lps) const |
Encodes the KEY 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 KEY resource record data from buffer pkt of length pktlen, starting at ptr. More... | |
Friends | |
| std::ostream & | operator<< (std::ostream &os, const RRDataKEY &key) |
| Print the KEY resource record data to an ostream in human readable form. More... | |
Encapsulates KEY resource record data.
See RFC 2535 for details. Note that RFC 2535 is basically dead with respect to DNSSEC, so no one should be using it for DNSSEC purposes, and probably shouldn't be using it at all.
| Dwm::Dns::RRDataKEY::RRDataKEY | ( | uint16_t | flags, |
| uint8_t | protocol, | ||
| uint8_t | algorithm, | ||
| uint16_t | moreFlags, | ||
| const std::string & | publicKey | ||
| ) |
Construct with the given flags, protocol, algorithm, moreFlags and publicKey.
|
virtual |
Decodes the KEY resource record data from buffer pkt of length pktlen, starting at ptr.
Returns the address immediately following the encoded KEY resource record data in pkt on success. Throws std::out_of_range if pkt was too short to contain an encoded KEY resource record data.
Implements Dwm::Dns::RRData.
|
virtual |
Encodes the KEY resource record data into buffer @ pkt of length pktlen, starting at ptr.
Returns the address immediately following the encoded KEY resource record data in pkt on success. Throws std::out_of_range if pkt is too short to contain the encoded KEY resource record data.
Implements Dwm::Dns::RRData.
|
friend |
Print the KEY resource record data to an ostream in human readable form.