#include <array>
#include <folly/crypto/Blake2xb.h>
#include <folly/lang/Bits.h>
namespace folly {
namespace crypto {
constexpr size_t Blake2xb::kMinOutputLength;
constexpr size_t Blake2xb::kMaxOutputLength;
constexpr size_t Blake2xb::kUnknownOutputLength;
namespace {
#if SODIUM_LIBRARY_VERSION_MAJOR > 10 || \
(SODIUM_LIBRARY_VERSION_MAJOR == 10 && SODIUM_LIBRARY_VERSION_MINOR >= 2)
struct _blake2b_state { … };
#define __LIBSODIUM_BLAKE2B_OPAQUE__ …
#endif
constexpr std::array<uint64_t, 8> kBlake2bIV = …;
void initStateFromParams(
crypto_generichash_blake2b_state* _state,
const detail::Blake2xbParam& param,
ByteRange key) { … }
}
Blake2xb::Blake2xb()
: … { … }
Blake2xb::~Blake2xb() = default;
void Blake2xb::init(
size_t outputLength,
ByteRange key ,
ByteRange salt ,
ByteRange personalization ) { … }
void Blake2xb::update(ByteRange data) { … }
void Blake2xb::finish(MutableByteRange out) { … }
}
}