17 static const char alphanum[] =
19 "ABCDEFGHIJKLMNOPQRSTUVWXYZ" 20 "abcdefghijklmnopqrstuvwxyz";
24 for (
size_t i = 0;
i < n; ++
i) {
38 trafficKey.
key =
toIOBuf(
"000102030405060708090A0B0C0D0E0F");
39 trafficKey.
iv =
toIOBuf(
"000102030405060708090A0B");
44 std::unique_ptr<Aead> aead;
45 std::vector<fizz::TLSMessage> msgs;
48 aead = std::make_unique<OpenSSLEVPCipher<AESGCM128>>();
51 for (
size_t i = 0;
i < n; ++
i) {
58 for (
auto& msg : msgs) {
70 #if FOLLY_OPENSSL_IS_110 && !defined(OPENSSL_NO_OCB) 72 std::unique_ptr<Aead> aead;
73 std::vector<fizz::TLSMessage> msgs;
76 aead = std::make_unique<OpenSSLEVPCipher<AESOCB128>>();
79 for (
size_t i = 0;
i < n; ++
i) {
86 for (
auto& msg : msgs) {
bool unhexlify(const InputString &input, OutputString &output)
void write(const T &in, folly::io::Appender &appender)
std::unique_ptr< folly::IOBuf > toIOBuf(std::string hexData)
#define BENCHMARK_SUSPEND
int main(int argc, char **argv)
constexpr detail::Map< Move > move
std::unique_ptr< folly::IOBuf > key
std::unique_ptr< folly::IOBuf > iv
virtual void setKey(TrafficKey key)=0
void encryptGCM(uint32_t n, size_t size)
void init(int *argc, char ***argv, bool removeFlags)
constexpr auto size(C const &c) -> decltype(c.size())
std::unique_ptr< folly::IOBuf > makeRandom(size_t n)
BENCHMARK_PARAM(encryptGCM, 10)
static std::unique_ptr< IOBuf > copyBuffer(const void *buf, std::size_t size, std::size_t headroom=0, std::size_t minTailroom=0)
auto doNotOptimizeAway(const T &datum) -> typename std::enable_if< !detail::DoNotOptimizeAwayNeedsIndirect< T >::value >::type