GNU libmicrohttpd 1.0.2
|
Calculation of SHA-1 digest. More...
Go to the source code of this file.
Data Structures | |
struct | sha1_ctx |
Macros | |
#define | _SHA1_DIGEST_LENGTH 5 |
#define | SHA1_WORD_SIZE_BITS 32 |
#define | SHA1_BYTES_IN_WORD (SHA1_WORD_SIZE_BITS / 8) |
#define | SHA1_DIGEST_SIZE (_SHA1_DIGEST_LENGTH * SHA1_BYTES_IN_WORD) |
#define | SHA1_DIGEST_STRING_SIZE ((SHA1_DIGEST_SIZE) * 2 + 1) |
#define | SHA1_BLOCK_SIZE_BITS 512 |
#define | SHA1_BLOCK_SIZE (SHA1_BLOCK_SIZE_BITS / 8) |
Functions | |
void | MHD_SHA1_init (void *ctx_) |
void | MHD_SHA1_update (void *ctx_, const uint8_t *data, size_t length) |
void | MHD_SHA1_finish (void *ctx_, uint8_t digest[SHA1_DIGEST_SIZE]) |
Calculation of SHA-1 digest.
Definition in file sha1.h.
#define _SHA1_DIGEST_LENGTH 5 |
SHA-1 digest is kept internally as 5 32-bit words.
Definition at line 38 of file sha1.h.
Referenced by MHD_SHA1_finish(), and sha1_transform().
#define SHA1_BLOCK_SIZE (SHA1_BLOCK_SIZE_BITS / 8) |
Size of single processing block in bytes
Definition at line 68 of file sha1.h.
Referenced by MHD_SHA1_finish(), MHD_SHA1_update(), and sha1_transform().
#define SHA1_BLOCK_SIZE_BITS 512 |
#define SHA1_BYTES_IN_WORD (SHA1_WORD_SIZE_BITS / 8) |
Number of bytes in single SHA-1 word
Definition at line 48 of file sha1.h.
Referenced by MHD_SHA1_finish().
#define SHA1_DIGEST_SIZE (_SHA1_DIGEST_LENGTH * SHA1_BYTES_IN_WORD) |
Size of SHA-1 digest in bytes
Definition at line 53 of file sha1.h.
Referenced by MHD_SHA1_finish().
#define SHA1_DIGEST_STRING_SIZE ((SHA1_DIGEST_SIZE) * 2 + 1) |
#define SHA1_WORD_SIZE_BITS 32 |
void MHD_SHA1_finish | ( | void * | ctx_, |
uint8_t | digest[SHA1_DIGEST_SIZE] ) |
Finalise SHA-1 calculation, return digest.
ctx_ | must be a struct sha1_ctx * | |
[out] | digest | set to the hash, must be SHA1_DIGEST_SIZE bytes |
< Number of processed bits
< Number of bytes in buffer
< Number of processed bits
< Number of bytes in buffer
void MHD_SHA1_init | ( | void * | ctx_ | ) |