]>
Commit | Line | Data |
---|---|---|
21dcbebc | 1 | /* |
33388b44 | 2 | * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved. |
58964a49 | 3 | * |
48f4ad77 | 4 | * Licensed under the Apache License 2.0 (the "License"). You may not use |
21dcbebc RS |
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 | |
58964a49 RE |
8 | */ |
9 | ||
ae4186b0 DMSP |
10 | #ifndef OPENSSL_RIPEMD_H |
11 | # define OPENSSL_RIPEMD_H | |
d86167ec DMSP |
12 | # pragma once |
13 | ||
14 | # include <openssl/macros.h> | |
936c2b9e | 15 | # ifndef OPENSSL_NO_DEPRECATED_3_0 |
d86167ec DMSP |
16 | # define HEADER_RIPEMD_H |
17 | # endif | |
58964a49 | 18 | |
3c27208f RS |
19 | # include <openssl/opensslconf.h> |
20 | ||
65167dba P |
21 | # ifndef OPENSSL_NO_RMD160 |
22 | # include <openssl/e_os2.h> | |
23 | # include <stddef.h> | |
601fca17 P |
24 | |
25 | # define RIPEMD160_DIGEST_LENGTH 20 | |
26 | ||
65167dba | 27 | # ifdef __cplusplus |
58964a49 | 28 | extern "C" { |
65167dba | 29 | # endif |
601fca17 | 30 | # if !defined(OPENSSL_NO_DEPRECATED_3_0) |
f5d7a031 | 31 | |
601fca17 | 32 | # define RIPEMD160_LONG unsigned int |
28e0be13 | 33 | |
601fca17 P |
34 | # define RIPEMD160_CBLOCK 64 |
35 | # define RIPEMD160_LBLOCK (RIPEMD160_CBLOCK/4) | |
58964a49 | 36 | |
0f113f3e MC |
37 | typedef struct RIPEMD160state_st { |
38 | RIPEMD160_LONG A, B, C, D, E; | |
39 | RIPEMD160_LONG Nl, Nh; | |
40 | RIPEMD160_LONG data[RIPEMD160_LBLOCK]; | |
41 | unsigned int num; | |
42 | } RIPEMD160_CTX; | |
601fca17 | 43 | # endif |
58964a49 | 44 | |
601fca17 P |
45 | DEPRECATEDIN_3_0(int RIPEMD160_Init(RIPEMD160_CTX *c)) |
46 | DEPRECATEDIN_3_0(int RIPEMD160_Update(RIPEMD160_CTX *c, const void *data, | |
47 | size_t len)) | |
48 | DEPRECATEDIN_3_0(int RIPEMD160_Final(unsigned char *md, RIPEMD160_CTX *c)) | |
49 | DEPRECATEDIN_3_0(unsigned char *RIPEMD160(const unsigned char *d, size_t n, | |
50 | unsigned char *md)) | |
51 | DEPRECATEDIN_3_0(void RIPEMD160_Transform(RIPEMD160_CTX *c, | |
52 | const unsigned char *b)) | |
3c27208f | 53 | |
65167dba | 54 | # ifdef __cplusplus |
58964a49 | 55 | } |
65167dba | 56 | # endif |
3c27208f | 57 | # endif |
58964a49 | 58 | #endif |