Implementation of the SHA-512/224 hashing function. More...
Implementation of the SHA-512/224 hashing function.
Files | |
file | sha512_224.h |
Header definitions for the SHA512/224 hash function. | |
Macros | |
#define | SHA512_224_DIGEST_LENGTH (28) |
Length of SHA512_224 digests in bytes. | |
#define | SHA512_224_INTERNAL_BLOCK_SIZE (128) |
1024 Bit (128 Byte) internally used block size for sha512_224 | |
Typedefs | |
typedef sha512_common_context_t | sha512_224_context_t |
Context for cipher operations based on sha512_224. | |
Functions | |
void | sha512_224_init (sha512_224_context_t *ctx) |
SHA-512/224 initialization. | |
static void | sha512_224_update (sha512_224_context_t *ctx, const void *data, size_t len) |
Add bytes into the hash. | |
static void | sha512_224_final (sha512_224_context_t *ctx, void *digest) |
SHA-512/224 finalization. | |
void | sha512_224 (const void *data, size_t len, void *digest) |
A wrapper function to simplify the generation of a hash. | |
#define SHA512_224_DIGEST_LENGTH (28) |
Length of SHA512_224 digests in bytes.
Definition at line 36 of file sha512_224.h.
#define SHA512_224_INTERNAL_BLOCK_SIZE (128) |
1024 Bit (128 Byte) internally used block size for sha512_224
Definition at line 41 of file sha512_224.h.
Context for cipher operations based on sha512_224.
Definition at line 46 of file sha512_224.h.
void sha512_224 | ( | const void * | data, |
size_t | len, | ||
void * | digest | ||
) |
A wrapper function to simplify the generation of a hash.
This is useful for generating sha512_224 for one single buffer in a single step.
[in] | data | pointer to the buffer to generate hash from |
[in] | len | length of the buffer |
[out] | digest | optional pointer to an array for the result, length must be at least SHA512_224_DIGEST_LENGTH |
|
inlinestatic |
SHA-512/224 finalization.
Pads the input data, exports the hash value, and clears the context state.
ctx | sha512_224_context_t handle to use, must not be NULL | |
[out] | digest | pointer to resulting digest, this is the hash of all the bytes. Length must be at least SHA512_224_DIGEST_LENGTH |
Definition at line 75 of file sha512_224.h.
void sha512_224_init | ( | sha512_224_context_t * | ctx | ) |
SHA-512/224 initialization.
Begins a SHA-512/224 operation.
ctx | sha512_224_context_t handle to init, must not be NULL |
|
inlinestatic |
Add bytes into the hash.
ctx | sha512_224_context_t handle to use, must not be NULL | |
[in] | data | Input data |
[in] | len | Length of data |
Definition at line 62 of file sha512_224.h.