Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-09-26 09:05:30

0001 /*
0002  * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
0003  *
0004  * Licensed under the Apache License 2.0 (the "License").  You may not use
0005  * this file except in compliance with the License.  You can obtain a copy
0006  * in the file LICENSE in the source distribution or at
0007  * https://www.openssl.org/source/license.html
0008  */
0009 
0010 #ifndef OPENSSL_MDC2_H
0011 #define OPENSSL_MDC2_H
0012 #pragma once
0013 
0014 #include <openssl/macros.h>
0015 #ifndef OPENSSL_NO_DEPRECATED_3_0
0016 #define HEADER_MDC2_H
0017 #endif
0018 
0019 #include <openssl/opensslconf.h>
0020 
0021 #ifndef OPENSSL_NO_MDC2
0022 #include <stdlib.h>
0023 #include <openssl/des.h>
0024 #ifdef __cplusplus
0025 extern "C" {
0026 #endif
0027 
0028 #define MDC2_DIGEST_LENGTH 16
0029 
0030 #if !defined(OPENSSL_NO_DEPRECATED_3_0)
0031 
0032 #define MDC2_BLOCK 8
0033 
0034 typedef struct mdc2_ctx_st {
0035     unsigned int num;
0036     unsigned char data[MDC2_BLOCK];
0037     DES_cblock h, hh;
0038     unsigned int pad_type; /* either 1 or 2, default 1 */
0039 } MDC2_CTX;
0040 #endif
0041 #ifndef OPENSSL_NO_DEPRECATED_3_0
0042 OSSL_DEPRECATEDIN_3_0 int MDC2_Init(MDC2_CTX *c);
0043 OSSL_DEPRECATEDIN_3_0 int MDC2_Update(MDC2_CTX *c, const unsigned char *data,
0044     size_t len);
0045 OSSL_DEPRECATEDIN_3_0 int MDC2_Final(unsigned char *md, MDC2_CTX *c);
0046 OSSL_DEPRECATEDIN_3_0 unsigned char *MDC2(const unsigned char *d, size_t n,
0047     unsigned char *md);
0048 #endif
0049 
0050 #ifdef __cplusplus
0051 }
0052 #endif
0053 #endif
0054 
0055 #endif