diff options
Diffstat (limited to 'src/lib/libcrypto/evp/m_wp.c')
| -rw-r--r-- | src/lib/libcrypto/evp/m_wp.c | 56 |
1 files changed, 0 insertions, 56 deletions
diff --git a/src/lib/libcrypto/evp/m_wp.c b/src/lib/libcrypto/evp/m_wp.c deleted file mode 100644 index 3f543ac0af..0000000000 --- a/src/lib/libcrypto/evp/m_wp.c +++ /dev/null | |||
| @@ -1,56 +0,0 @@ | |||
| 1 | /* $OpenBSD: m_wp.c,v 1.8 2014/07/13 09:30:02 miod Exp $ */ | ||
| 2 | |||
| 3 | #include <stdio.h> | ||
| 4 | |||
| 5 | #include <openssl/opensslconf.h> | ||
| 6 | |||
| 7 | #ifndef OPENSSL_NO_WHIRLPOOL | ||
| 8 | |||
| 9 | #include <openssl/evp.h> | ||
| 10 | #include <openssl/objects.h> | ||
| 11 | #include <openssl/x509.h> | ||
| 12 | #include <openssl/whrlpool.h> | ||
| 13 | |||
| 14 | static int | ||
| 15 | init(EVP_MD_CTX *ctx) | ||
| 16 | { | ||
| 17 | return WHIRLPOOL_Init(ctx->md_data); | ||
| 18 | } | ||
| 19 | |||
| 20 | static int | ||
| 21 | update(EVP_MD_CTX *ctx, const void *data, size_t count) | ||
| 22 | { | ||
| 23 | return WHIRLPOOL_Update(ctx->md_data, data, count); | ||
| 24 | } | ||
| 25 | |||
| 26 | static int | ||
| 27 | final(EVP_MD_CTX *ctx, unsigned char *md) | ||
| 28 | { | ||
| 29 | return WHIRLPOOL_Final(md, ctx->md_data); | ||
| 30 | } | ||
| 31 | |||
| 32 | static const EVP_MD whirlpool_md = { | ||
| 33 | .type = NID_whirlpool, | ||
| 34 | .pkey_type = 0, | ||
| 35 | .md_size = WHIRLPOOL_DIGEST_LENGTH, | ||
| 36 | .flags = 0, | ||
| 37 | .init = init, | ||
| 38 | .update = update, | ||
| 39 | .final = final, | ||
| 40 | .copy = NULL, | ||
| 41 | .cleanup = NULL, | ||
| 42 | .sign = NULL, | ||
| 43 | .verify = NULL, | ||
| 44 | .required_pkey_type = { | ||
| 45 | 0, 0, 0, 0, | ||
| 46 | }, | ||
| 47 | .block_size = WHIRLPOOL_BBLOCK / 8, | ||
| 48 | .ctx_size = sizeof(EVP_MD *) + sizeof(WHIRLPOOL_CTX), | ||
| 49 | }; | ||
| 50 | |||
| 51 | const EVP_MD * | ||
| 52 | EVP_whirlpool(void) | ||
| 53 | { | ||
| 54 | return (&whirlpool_md); | ||
| 55 | } | ||
| 56 | #endif | ||
