table of contents
LIBKECCAK_STATE_DUPLICATE(3) | Library Functions Manual | LIBKECCAK_STATE_DUPLICATE(3) |
NAME¶
libkeccak_state_duplicate - Allocate a duplicate hash state
SYNOPSIS¶
#include <libkeccak.h> struct libkeccak_state *libkeccak_state_duplicate(const struct libkeccak_state *src);
Link with -lkeccakP.
DESCRIPTION¶
The libkeccak_state_duplicate() function allocates a new hash state and initialises it to be identical to *src. This includes all members of the struct libkeccak_state structure, including the state of the sponge and the message chunk buffer.
RETURN VALUES¶
The libkeccak_state_duplicate() function returns a newly allocated struct libkeccak_state* (of one initialised element) upon successful completion. On error, NULL is returned and errno is set to describe the error.
ERRORS¶
The libkeccak_state_duplicate() function may fail for any specified for the function malloc(3).
SEE ALSO¶
LIBKECCAK |