2 chacha-merged.c version 20080118
10 #include <sys/types.h>
15 #define CHACHA_BLOCKLEN 64
17 /* use memcpy() to copy blocks of memory (typically faster) */
19 /* use unaligned little-endian load/store (can be faster) */
20 #define USE_UNALIGNED 0
26 void chacha_keysetup(struct chacha_ctx *x, const unsigned char *k,
28 void chacha_ivsetup(struct chacha_ctx *x, const unsigned char *iv,
29 const unsigned char *ctr);
30 void chacha_encrypt_bytes(struct chacha_ctx *x, const unsigned char *m,
31 unsigned char *c, uint32_t bytes);