20#include <xrpl/basics/base64.h>
22#include <doctest/doctest.h>
42 check(
"foob",
"Zm9vYg==");
43 check(
"fooba",
"Zm9vYmE=");
44 check(
"foobar",
"Zm9vYmFy");
47 "Man is distinguished, not only by his reason, but by this "
48 "singular passion from "
49 "other animals, which is a lust of the mind, that by a "
50 "perseverance of delight "
51 "in the continued and indefatigable generation of knowledge, "
53 "vehemence of any carnal pleasure.",
54 "TWFuIGlzIGRpc3Rpbmd1aXNoZWQsIG5vdCBvbmx5IGJ5IGhpcyByZWFzb24sIGJ1dC"
56 "IHNpbmd1bGFyIHBhc3Npb24gZnJvbSBvdGhlciBhbmltYWxzLCB3aGljaCBpcyBhIG"
58 "dGhlIG1pbmQsIHRoYXQgYnkgYSBwZXJzZXZlcmFuY2Ugb2YgZGVsaWdodCBpbiB0aG"
60 "dWVkIGFuZCBpbmRlZmF0aWdhYmxlIGdlbmVyYXRpb24gb2Yga25vd2xlZGdlLCBleG"
62 "ZSBzaG9ydCB2ZWhlbWVuY2Ugb2YgYW55IGNhcm5hbCBwbGVhc3VyZS4=");
void check(bool condition, std::string const &message)
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
std::string base64_decode(std::string_view data)
std::string base64_encode(std::uint8_t const *data, std::size_t len)