diff options
author | markus <> | 2002-09-05 12:51:50 +0000 |
---|---|---|
committer | markus <> | 2002-09-05 12:51:50 +0000 |
commit | 15b5d84f9da2ce4bfae8580e56e34a859f74ad71 (patch) | |
tree | bf939e82d7fd73cc8a01cf6959002209972091bc /src/lib/libcrypto/idea | |
parent | 027351f729b9e837200dae6e1520cda6577ab930 (diff) | |
download | openbsd-15b5d84f9da2ce4bfae8580e56e34a859f74ad71.tar.gz openbsd-15b5d84f9da2ce4bfae8580e56e34a859f74ad71.tar.bz2 openbsd-15b5d84f9da2ce4bfae8580e56e34a859f74ad71.zip |
import openssl-0.9.7-beta1
Diffstat (limited to 'src/lib/libcrypto/idea')
-rw-r--r-- | src/lib/libcrypto/idea/idea.h | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/src/lib/libcrypto/idea/idea.h b/src/lib/libcrypto/idea/idea.h index ae32f5692e..67132414ee 100644 --- a/src/lib/libcrypto/idea/idea.h +++ b/src/lib/libcrypto/idea/idea.h | |||
@@ -59,11 +59,7 @@ | |||
59 | #ifndef HEADER_IDEA_H | 59 | #ifndef HEADER_IDEA_H |
60 | #define HEADER_IDEA_H | 60 | #define HEADER_IDEA_H |
61 | 61 | ||
62 | #ifdef __cplusplus | 62 | #ifdef OPENSSL_NO_IDEA |
63 | extern "C" { | ||
64 | #endif | ||
65 | |||
66 | #ifdef NO_IDEA | ||
67 | #error IDEA is disabled. | 63 | #error IDEA is disabled. |
68 | #endif | 64 | #endif |
69 | 65 | ||
@@ -74,22 +70,26 @@ extern "C" { | |||
74 | #define IDEA_BLOCK 8 | 70 | #define IDEA_BLOCK 8 |
75 | #define IDEA_KEY_LENGTH 16 | 71 | #define IDEA_KEY_LENGTH 16 |
76 | 72 | ||
73 | #ifdef __cplusplus | ||
74 | extern "C" { | ||
75 | #endif | ||
76 | |||
77 | typedef struct idea_key_st | 77 | typedef struct idea_key_st |
78 | { | 78 | { |
79 | IDEA_INT data[9][6]; | 79 | IDEA_INT data[9][6]; |
80 | } IDEA_KEY_SCHEDULE; | 80 | } IDEA_KEY_SCHEDULE; |
81 | 81 | ||
82 | const char *idea_options(void); | 82 | const char *idea_options(void); |
83 | void idea_ecb_encrypt(unsigned char *in, unsigned char *out, | 83 | void idea_ecb_encrypt(const unsigned char *in, unsigned char *out, |
84 | IDEA_KEY_SCHEDULE *ks); | 84 | IDEA_KEY_SCHEDULE *ks); |
85 | void idea_set_encrypt_key(unsigned char *key, IDEA_KEY_SCHEDULE *ks); | 85 | void idea_set_encrypt_key(const unsigned char *key, IDEA_KEY_SCHEDULE *ks); |
86 | void idea_set_decrypt_key(IDEA_KEY_SCHEDULE *ek, IDEA_KEY_SCHEDULE *dk); | 86 | void idea_set_decrypt_key(IDEA_KEY_SCHEDULE *ek, IDEA_KEY_SCHEDULE *dk); |
87 | void idea_cbc_encrypt(unsigned char *in, unsigned char *out, | 87 | void idea_cbc_encrypt(const unsigned char *in, unsigned char *out, |
88 | long length, IDEA_KEY_SCHEDULE *ks, unsigned char *iv,int enc); | 88 | long length, IDEA_KEY_SCHEDULE *ks, unsigned char *iv,int enc); |
89 | void idea_cfb64_encrypt(unsigned char *in, unsigned char *out, | 89 | void idea_cfb64_encrypt(const unsigned char *in, unsigned char *out, |
90 | long length, IDEA_KEY_SCHEDULE *ks, unsigned char *iv, | 90 | long length, IDEA_KEY_SCHEDULE *ks, unsigned char *iv, |
91 | int *num,int enc); | 91 | int *num,int enc); |
92 | void idea_ofb64_encrypt(unsigned char *in, unsigned char *out, | 92 | void idea_ofb64_encrypt(const unsigned char *in, unsigned char *out, |
93 | long length, IDEA_KEY_SCHEDULE *ks, unsigned char *iv, int *num); | 93 | long length, IDEA_KEY_SCHEDULE *ks, unsigned char *iv, int *num); |
94 | void idea_encrypt(unsigned long *in, IDEA_KEY_SCHEDULE *ks); | 94 | void idea_encrypt(unsigned long *in, IDEA_KEY_SCHEDULE *ks); |
95 | #ifdef __cplusplus | 95 | #ifdef __cplusplus |