My Project
|
Functions | |
int | wc_InitBlake2b (Blake2b *b2b, word32 digestSz) |
This function initializes a Blake2b structure for use with the Blake2 hash function. More... | |
int | wc_Blake2bUpdate (Blake2b *b2b, const byte *data, word32 sz) |
This function updates the Blake2b hash with the given input data. This function should be called after wc_InitBlake2b, and repeated until one is ready for the final hash: wc_Blake2bFinal. More... | |
int | wc_Blake2bFinal (Blake2b *b2b, byte *final, word32 requestSz) |
This function computes the Blake2b hash of the previously supplied input data. The output hash will be of length requestSz, or, if requestSz==0, the digestSz of the b2b structure. This function should be called after wc_InitBlake2b and wc_Blake2bUpdate has been processed for each piece of input data desired. More... | |
int wc_Blake2bFinal | ( | Blake2b * | b2b, |
byte * | final, | ||
word32 | requestSz | ||
) |
This function computes the Blake2b hash of the previously supplied input data. The output hash will be of length requestSz, or, if requestSz==0, the digestSz of the b2b structure. This function should be called after wc_InitBlake2b and wc_Blake2bUpdate has been processed for each piece of input data desired.
b2b | pointer to the Blake2b structure to update |
final | pointer to a buffer in which to store the blake2b hash. Should be of length requestSz |
requestSz | length of the digest to compute. When this is zero, b2b->digestSz will be used instead |
Example
int wc_Blake2bUpdate | ( | Blake2b * | b2b, |
const byte * | data, | ||
word32 | sz | ||
) |
This function updates the Blake2b hash with the given input data. This function should be called after wc_InitBlake2b, and repeated until one is ready for the final hash: wc_Blake2bFinal.
b2b | pointer to the Blake2b structure to update |
data | pointer to a buffer containing the data to append |
sz | length of the input data to append |
Example
int wc_InitBlake2b | ( | Blake2b * | b2b, |
word32 | digestSz | ||
) |
This function initializes a Blake2b structure for use with the Blake2 hash function.
b2b | pointer to the Blake2b structure to initialize |
digestSz | length of the blake 2 digest to implement |
Example