diff options
Diffstat (limited to 'src/lib/libcrypto/evp/m_null.c')
| -rw-r--r-- | src/lib/libcrypto/evp/m_null.c | 31 |
1 files changed, 19 insertions, 12 deletions
diff --git a/src/lib/libcrypto/evp/m_null.c b/src/lib/libcrypto/evp/m_null.c index 6d80560df2..f6f0a1d2c0 100644 --- a/src/lib/libcrypto/evp/m_null.c +++ b/src/lib/libcrypto/evp/m_null.c | |||
| @@ -58,29 +58,36 @@ | |||
| 58 | 58 | ||
| 59 | #include <stdio.h> | 59 | #include <stdio.h> |
| 60 | #include "cryptlib.h" | 60 | #include "cryptlib.h" |
| 61 | #include "evp.h" | 61 | #include <openssl/evp.h> |
| 62 | #include "objects.h" | 62 | #include <openssl/objects.h> |
| 63 | #include "x509.h" | 63 | #include <openssl/x509.h> |
| 64 | 64 | ||
| 65 | static void function() | 65 | static int init(EVP_MD_CTX *ctx) |
| 66 | { | 66 | { return 1; } |
| 67 | } | 67 | |
| 68 | static int update(EVP_MD_CTX *ctx,const void *data,unsigned long count) | ||
| 69 | { return 1; } | ||
| 68 | 70 | ||
| 69 | static EVP_MD null_md= | 71 | static int final(EVP_MD_CTX *ctx,unsigned char *md) |
| 72 | { return 1; } | ||
| 73 | |||
| 74 | static const EVP_MD null_md= | ||
| 70 | { | 75 | { |
| 71 | NID_undef, | 76 | NID_undef, |
| 72 | NID_undef, | 77 | NID_undef, |
| 73 | 0, | 78 | 0, |
| 74 | function, | 79 | 0, |
| 75 | function, | 80 | init, |
| 76 | function, | 81 | update, |
| 77 | 82 | final, | |
| 83 | NULL, | ||
| 84 | NULL, | ||
| 78 | EVP_PKEY_NULL_method, | 85 | EVP_PKEY_NULL_method, |
| 79 | 0, | 86 | 0, |
| 80 | sizeof(EVP_MD *), | 87 | sizeof(EVP_MD *), |
| 81 | }; | 88 | }; |
| 82 | 89 | ||
| 83 | EVP_MD *EVP_md_null() | 90 | const EVP_MD *EVP_md_null(void) |
| 84 | { | 91 | { |
| 85 | return(&null_md); | 92 | return(&null_md); |
| 86 | } | 93 | } |
