Blake2s.h File Reference
#include "HashApi/blake2s.h"
#include "HashEngine.h"
#include "HashContext.h"
#include "HmacContext.h"
Include dependency graph for Blake2s.h:

Go to the source code of this file.

Namespaces

 Crypto
 

Macros

#define BLAKE2S_INIT(name_)
 

Typedefs

template<size_t hashsize>
using Crypto::Blake2s = HashContext< Blake2sEngine< hashsize > >
 
using Crypto::Blake2s256 = Blake2s< 32 >
 
using Crypto::Blake2s128 = Blake2s< 16 >
 
template<size_t hashsize>
using Crypto::HmacBlake2s = HmacContext< Blake2s< hashsize > >
 
using Crypto::HmacBlake2s256 = HmacBlake2s< 32 >
 
using Crypto::HmacBlake2s128 = HmacBlake2s< 16 >
 

Macro Definition Documentation

◆ BLAKE2S_INIT

#define BLAKE2S_INIT (   name_)
Value:
static_assert(hash_size > 0 && hash_size <= BLAKE2S_MAXHASHSIZE, "Blake2s invalid hashsize"); \
\
void init() \
{ \
CRYPTO_NAME(name_, initkey)(&ctx, hash_size, nullptr, 0); \
} \
\
void init(const Secret& key) \
{ \
CRYPTO_NAME(name_, initkey)(&ctx, hash_size, key.data(), key.size()); \
}
#define BLAKE2S_MAXHASHSIZE
Definition: blake2s.h:19
void size_t const void * key
Definition: blake2s.h:33
Blob Secret
Identifies data which should be treated with care.
Definition: Blob.h:49