p[3] = (unsigned char)((v >> 24) & 0xff);
}
-static size_t
+size_t
poly1305_block_size_ref(void) {
return POLY1305_BLOCK_SIZE;
}
-static void
+void
poly1305_init_ext_ref(void *state, const poly1305_key *key, size_t bytes_hint) {
poly1305_state_ref_t *st = (poly1305_state_ref_t *)state;
st->final = 0;
}
-static void
+void
poly1305_blocks_ref(void *state, const unsigned char *in, size_t inlen) {
poly1305_state_ref_t *st = (poly1305_state_ref_t *)state;
const uint32_t hibit = (st->final) ? 0 : (1 << 24); /* 1 << 128 */
st->h[4] = h4;
}
-static void
+void
poly1305_finish_ext_ref(void *state, const unsigned char *in, size_t remaining, unsigned char mac[16]) {
poly1305_state_ref_t *st = (poly1305_state_ref_t *)state;
uint32_t h0,h1,h2,h3,h4,c;
st->pad[3] = 0;
}
-static void
+void
poly1305_auth_ref(unsigned char mac[16], const unsigned char *in, size_t inlen, const poly1305_key *key) {
poly1305_state_ref_t st;
size_t blocks;