Kea 2.7.6
|
Classes | |
class | Base16Encoder |
Class for encoding and decoding binary data using Base16 (aka Hex) as described in RFC 4648. More... | |
class | Base32HexEncoder |
Class for encoding and decoding binary data using Base32Hex as described in RFC 4648. More... | |
class | Base64Encoder |
Class for encoding and decoding binary data using Base64 as described in RFC 4648. More... | |
class | BaseNEncoder |
Class for encoding and decoding binary data using an algorithm described in RFC 4648. More... | |
Functions | |
void | decodeBase32Hex (const std::string &encoded_str, std::vector< uint8_t > &output) |
Decode a base32-hex encoded string into binary data. | |
void | decodeBase64 (const std::string &encoded_str, std::vector< uint8_t > &output) |
Decode a base64 encoded string into binary data. | |
void | decodeHex (const std::string &encoded_str, std::vector< uint8_t > &output) |
Decode a base16 encoded string into binary data. | |
string | encodeBase32Hex (const std::vector< uint8_t > &binary) |
Encode binary data in the base32-hex format. | |
string | encodeBase64 (const std::vector< uint8_t > &binary) |
Encode binary data in the base64 format. | |
string | encodeHex (const std::vector< uint8_t > &binary) |
Encode binary data in the base16 format. | |
std::vector< uint8_t > | encodeUtf8 (const std::string &value) |
Encode value string into UTF-8. | |
std::string | toHex (std::string value) |
Encode in hexadecimal inline. | |
void isc::util::encode::decodeBase32Hex | ( | const std::string & | encoded_str, |
std::vector< uint8_t > & | output ) |
Decode a base32-hex encoded string into binary data.
encoded_str | string containing a base32-hex encoded value. | |
[out] | output | vector into which the decoded binary data is stored. |
BadValue | if the input string is invalid. |
Definition at line 355 of file encode.cc.
References isc::util::encode::BaseNEncoder::decode().
void isc::util::encode::decodeBase64 | ( | const std::string & | encoded_str, |
std::vector< uint8_t > & | output ) |
Decode a base64 encoded string into binary data.
encoded_str | string containing a base64 encoded value. | |
[out] | output | vector into which the decoded binary data is stored. |
BadValue | if the input string is invalid. |
Definition at line 343 of file encode.cc.
References isc::util::encode::BaseNEncoder::decode().
Referenced by isc::dns::TSIGKey::TSIGKey(), and isc::yang::Translator::decode64().
void isc::util::encode::decodeHex | ( | const std::string & | encoded_str, |
std::vector< uint8_t > & | output ) |
Decode a base16 encoded string into binary data.
encoded_str | string containing a base16 encoded value. | |
[out] | output | vector into which the decoded binary data is stored. |
BadValue | if the input string is invalid. |
Definition at line 367 of file encode.cc.
References isc::util::encode::BaseNEncoder::decode().
Referenced by isc::dhcp::TokenHexString::TokenHexString(), user_chk::UserId::UserId(), isc::dhcp::LeaseMgr::addExtendedInfo6(), isc::util::str::decodeFormattedHexString(), isc::dhcp::LeaseMgr::extractLease4ExtendedInfo(), isc::dhcp_ddns::D2Dhcid::fromStr(), isc::dhcp::AuthKey::setAuthKey(), isc::dhcp::CfgDUID::setIdentifier(), isc::dhcp::LeaseMgr::upgradeLease4ExtendedInfo(), isc::dhcp::LeaseMgr::upgradeLease6ExtendedInfo(), and isc::dhcp::OptionDataTypeUtil::writeBinary().
std::string isc::util::encode::encodeBase32Hex | ( | const std::vector< uint8_t > & | binary | ) |
Encode binary data in the base32-hex format.
binary | vector object storing the data to be encoded. |
Definition at line 349 of file encode.cc.
References isc::util::encode::BaseNEncoder::encode().
std::string isc::util::encode::encodeBase64 | ( | const std::vector< uint8_t > & | binary | ) |
Encode binary data in the base64 format.
binary | vector object storing the data to be encoded. |
Definition at line 337 of file encode.cc.
References isc::util::encode::BaseNEncoder::encode().
Referenced by isc::yang::Translator::encode64(), and isc::dns::TSIGKey::toText().
std::string isc::util::encode::encodeHex | ( | const std::vector< uint8_t > & | binary | ) |
Encode binary data in the base16 format.
binary | vector object containing the data to be encoded. |
Definition at line 361 of file encode.cc.
References isc::util::encode::BaseNEncoder::encode().
Referenced by isc::dhcp::TokenVendor::evaluate(), isc::dhcp::TokenVendorClass::evaluate(), isc::config::BaseCommandMgr::getHash(), isc::dhcp::Host::getIdentifierAsText(), isc::d2::D2CfgMgr::reverseV6Address(), isc::dhcp::CfgDUID::toElement(), isc::dhcp::Host::toElement4(), isc::dhcp::Host::toElement6(), isc::dhcp::CfgOption::toElementWithMetadata(), toHex(), isc::dhcp::Option::toHexString(), isc::dhcp_ddns::D2Dhcid::toStr(), isc::dhcp::AuthKey::toText(), isc::dhcp::Option6Auth::toText(), isc::dhcp::Option6PDExclude::toText(), isc::dhcp::AllocEngine::updateLease4ExtendedInfo(), isc::dhcp::AllocEngine::updateLease6ExtendedInfo(), isc::dhcp::LeaseMgr::upgradeLease4ExtendedInfo(), and isc::dhcp::LeaseMgr::upgradeLease6ExtendedInfo().
std::vector< uint8_t > isc::util::encode::encodeUtf8 | ( | const std::string & | value | ) |
|
inline |
Encode in hexadecimal inline.
value | the value to encode. |
Definition at line 293 of file encode.h.
References encodeHex().