File indexing completed on 2026-05-18 08:31:06
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010 #ifndef OPENSSL_RC5_H
0011 #define OPENSSL_RC5_H
0012 #pragma once
0013
0014 #include <openssl/macros.h>
0015 #ifndef OPENSSL_NO_DEPRECATED_3_0
0016 #define HEADER_RC5_H
0017 #endif
0018
0019 #include <openssl/opensslconf.h>
0020
0021 #ifndef OPENSSL_NO_RC5
0022 #ifdef __cplusplus
0023 extern "C" {
0024 #endif
0025
0026 #define RC5_32_BLOCK 8
0027 #define RC5_32_KEY_LENGTH 16
0028
0029 #ifndef OPENSSL_NO_DEPRECATED_3_0
0030 #define RC5_ENCRYPT 1
0031 #define RC5_DECRYPT 0
0032
0033 #define RC5_32_INT unsigned int
0034
0035
0036
0037
0038
0039 #define RC5_8_ROUNDS 8
0040 #define RC5_12_ROUNDS 12
0041 #define RC5_16_ROUNDS 16
0042
0043 typedef struct rc5_key_st {
0044
0045 int rounds;
0046 RC5_32_INT data[2 * (RC5_16_ROUNDS + 1)];
0047 } RC5_32_KEY;
0048 #endif
0049 #ifndef OPENSSL_NO_DEPRECATED_3_0
0050 OSSL_DEPRECATEDIN_3_0 int RC5_32_set_key(RC5_32_KEY *key, int len,
0051 const unsigned char *data,
0052 int rounds);
0053 OSSL_DEPRECATEDIN_3_0 void RC5_32_ecb_encrypt(const unsigned char *in,
0054 unsigned char *out,
0055 RC5_32_KEY *key,
0056 int enc);
0057 OSSL_DEPRECATEDIN_3_0 void RC5_32_encrypt(unsigned long *data, RC5_32_KEY *key);
0058 OSSL_DEPRECATEDIN_3_0 void RC5_32_decrypt(unsigned long *data, RC5_32_KEY *key);
0059 OSSL_DEPRECATEDIN_3_0 void RC5_32_cbc_encrypt(const unsigned char *in,
0060 unsigned char *out, long length,
0061 RC5_32_KEY *ks, unsigned char *iv,
0062 int enc);
0063 OSSL_DEPRECATEDIN_3_0 void RC5_32_cfb64_encrypt(const unsigned char *in,
0064 unsigned char *out, long length,
0065 RC5_32_KEY *schedule,
0066 unsigned char *ivec, int *num,
0067 int enc);
0068 OSSL_DEPRECATEDIN_3_0 void RC5_32_ofb64_encrypt(const unsigned char *in,
0069 unsigned char *out, long length,
0070 RC5_32_KEY *schedule,
0071 unsigned char *ivec, int *num);
0072 #endif
0073
0074 #ifdef __cplusplus
0075 }
0076 #endif
0077 #endif
0078
0079 #endif