summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/chacha/chacha.h
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/lib/libcrypto/chacha/chacha.h53
1 files changed, 0 insertions, 53 deletions
diff --git a/src/lib/libcrypto/chacha/chacha.h b/src/lib/libcrypto/chacha/chacha.h
deleted file mode 100644
index 8af5ef856f..0000000000
--- a/src/lib/libcrypto/chacha/chacha.h
+++ /dev/null
@@ -1,53 +0,0 @@
1/* $OpenBSD: chacha.h,v 1.6 2014/07/25 14:04:51 jsing Exp $ */
2/*
3 * Copyright (c) 2014 Joel Sing <jsing@openbsd.org>
4 *
5 * Permission to use, copy, modify, and distribute this software for any
6 * purpose with or without fee is hereby granted, provided that the above
7 * copyright notice and this permission notice appear in all copies.
8 *
9 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
10 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
11 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
12 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
13 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
14 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
15 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
16 */
17
18#ifndef HEADER_CHACHA_H
19#define HEADER_CHACHA_H
20
21#include <openssl/opensslconf.h>
22
23#if defined(OPENSSL_NO_CHACHA)
24#error ChaCha is disabled.
25#endif
26
27#include <stddef.h>
28
29#ifdef __cplusplus
30extern "C" {
31#endif
32
33typedef struct {
34 unsigned int input[16];
35 unsigned char ks[64];
36 unsigned char unused;
37} ChaCha_ctx;
38
39void ChaCha_set_key(ChaCha_ctx *ctx, const unsigned char *key,
40 unsigned int keybits);
41void ChaCha_set_iv(ChaCha_ctx *ctx, const unsigned char *iv,
42 const unsigned char *counter);
43void ChaCha(ChaCha_ctx *ctx, unsigned char *out, const unsigned char *in,
44 size_t len);
45
46void CRYPTO_chacha_20(unsigned char *out, const unsigned char *in, size_t len,
47 const unsigned char key[32], const unsigned char iv[8], size_t counter);
48
49#ifdef __cplusplus
50}
51#endif
52
53#endif /* HEADER_CHACHA_H */