#include "nettle-internal.h"
void
-cbc_encrypt(void *ctx, void (*f)(void *ctx,
- unsigned length, uint8_t *dst,
- const uint8_t *src),
+cbc_encrypt(const void *ctx, void (*f)(const void *ctx,
+ unsigned length, uint8_t *dst,
+ const uint8_t *src),
unsigned block_size, uint8_t *iv,
unsigned length, uint8_t *dst,
const uint8_t *src)
/* Reqires that dst != src */
static void
-cbc_decrypt_internal(void *ctx, void (*f)(void *ctx,
- unsigned length, uint8_t *dst,
- const uint8_t *src),
+cbc_decrypt_internal(const void *ctx, void (*f)(const void *ctx,
+ unsigned length, uint8_t *dst,
+ const uint8_t *src),
unsigned block_size, uint8_t *iv,
unsigned length, uint8_t *dst,
const uint8_t *src)
#define CBC_BUFFER_LIMIT 4096
void
-cbc_decrypt(void *ctx, void (*f)(void *ctx,
- unsigned length, uint8_t *dst,
- const uint8_t *src),
+cbc_decrypt(const void *ctx, void (*f)(const void *ctx,
+ unsigned length, uint8_t *dst,
+ const uint8_t *src),
unsigned block_size, uint8_t *iv,
unsigned length, uint8_t *dst,
const uint8_t *src)
/* Uses a void * for cipher contexts. */
void
-cbc_encrypt(void *ctx, void (*f)(void *ctx,
- unsigned length, uint8_t *dst,
- const uint8_t *src),
+cbc_encrypt(const void *ctx, void (*f)(const void *ctx,
+ unsigned length, uint8_t *dst,
+ const uint8_t *src),
unsigned block_size, uint8_t *iv,
unsigned length, uint8_t *dst,
const uint8_t *src);
void
-cbc_decrypt(void *ctx, void (*f)(void *ctx,
- unsigned length, uint8_t *dst,
- const uint8_t *src),
+cbc_decrypt(const void *ctx, void (*f)(const void *ctx,
+ unsigned length, uint8_t *dst,
+ const uint8_t *src),
unsigned block_size, uint8_t *iv,
unsigned length, uint8_t *dst,
const uint8_t *src);