NeoMutt  2024-10-02-37-gfa9146
Teaching an old dog new tricks
DOXYGEN
Loading...
Searching...
No Matches
md5.h
Go to the documentation of this file.
1
23#ifndef MUTT_MUTT_MD5_H
24#define MUTT_MUTT_MD5_H
25
26#include <stdint.h>
27#include <stdio.h>
28
29typedef uint32_t md5_uint32;
30
36struct Md5Ctx
37{
42
46};
47
48void *mutt_md5(const char *str, void *buf);
49void *mutt_md5_bytes(const void *buffer, size_t len, void *resbuf);
50void *mutt_md5_finish_ctx(struct Md5Ctx *md5ctx, void *resbuf);
51void mutt_md5_init_ctx(struct Md5Ctx *md5ctx);
52void mutt_md5_process(const char *str, struct Md5Ctx *md5ctx);
53void mutt_md5_process_bytes(const void *buf, size_t buflen, struct Md5Ctx *md5ctx);
54void mutt_md5_toascii(const void *digest, char *resbuf);
55
56#endif /* MUTT_MUTT_MD5_H */
void * mutt_md5(const char *str, void *buf)
Calculate the MD5 hash of a NULL-terminated string.
Definition: md5.c:317
void mutt_md5_process_bytes(const void *buf, size_t buflen, struct Md5Ctx *md5ctx)
Process a block of data.
Definition: md5.c:373
void * mutt_md5_bytes(const void *buffer, size_t len, void *resbuf)
Calculate the MD5 hash of a buffer.
Definition: md5.c:336
void mutt_md5_process(const char *str, struct Md5Ctx *md5ctx)
Process a NULL-terminated string.
Definition: md5.c:355
uint32_t md5_uint32
Definition: md5.h:29
void mutt_md5_init_ctx(struct Md5Ctx *md5ctx)
Initialise the MD5 computation.
Definition: md5.c:261
void * mutt_md5_finish_ctx(struct Md5Ctx *md5ctx, void *resbuf)
Process the remaining bytes in the buffer.
Definition: md5.c:285
void mutt_md5_toascii(const void *digest, char *resbuf)
Convert a binary MD5 digest into ASCII Hexadecimal.
Definition: md5.c:456
Cursor for the MD5 hashing.
Definition: md5.h:37
md5_uint32 total[2]
Definition: md5.h:43
md5_uint32 D
Definition: md5.h:41
md5_uint32 C
Definition: md5.h:40
md5_uint32 buflen
Definition: md5.h:44
md5_uint32 A
Definition: md5.h:38
md5_uint32 B
Definition: md5.h:39
md5_uint32 buffer[32]
Definition: md5.h:45