]>
Commit | Line | Data |
---|---|---|
3f5616d7 | 1 | /* |
1212818e | 2 | * Copyright 2017-2018 The OpenSSL Project Authors. All Rights Reserved. |
3f5616d7 | 3 | * |
48f4ad77 | 4 | * Licensed under the Apache License 2.0 (the "License"). You may not use |
3f5616d7 TS |
5 | * this file except in compliance with the License. You can obtain a copy |
6 | * in the file LICENSE in the source distribution or at | |
7 | * https://www.openssl.org/source/license.html | |
8 | */ | |
9 | ||
10 | #include <stddef.h> | |
11 | ||
12 | #define SIPHASH_BLOCK_SIZE 8 | |
13 | #define SIPHASH_KEY_SIZE 16 | |
14 | #define SIPHASH_MIN_DIGEST_SIZE 8 | |
15 | #define SIPHASH_MAX_DIGEST_SIZE 16 | |
16 | ||
17 | typedef struct siphash_st SIPHASH; | |
18 | ||
19 | size_t SipHash_ctx_size(void); | |
20 | size_t SipHash_hash_size(SIPHASH *ctx); | |
d74f23d2 RL |
21 | int SipHash_set_hash_size(SIPHASH *ctx, size_t hash_size); |
22 | int SipHash_Init(SIPHASH *ctx, const unsigned char *k, | |
3f5616d7 TS |
23 | int crounds, int drounds); |
24 | void SipHash_Update(SIPHASH *ctx, const unsigned char *in, size_t inlen); | |
25 | int SipHash_Final(SIPHASH *ctx, unsigned char *out, size_t outlen); |