diff options
author | beck <> | 1999-09-29 04:37:45 +0000 |
---|---|---|
committer | beck <> | 1999-09-29 04:37:45 +0000 |
commit | de8f24ea083384bb66b32ec105dc4743c5663cdf (patch) | |
tree | 1412176ae62a3cab2cf2b0b92150fcbceaac6092 /src/lib/libcrypto/evp/e_ecb_r5.c | |
parent | cb929d29896bcb87c2a97417fbd03e50078fc178 (diff) | |
download | openbsd-de8f24ea083384bb66b32ec105dc4743c5663cdf.tar.gz openbsd-de8f24ea083384bb66b32ec105dc4743c5663cdf.tar.bz2 openbsd-de8f24ea083384bb66b32ec105dc4743c5663cdf.zip |
OpenSSL 0.9.4 merge
Diffstat (limited to 'src/lib/libcrypto/evp/e_ecb_r5.c')
-rw-r--r-- | src/lib/libcrypto/evp/e_ecb_r5.c | 26 |
1 files changed, 7 insertions, 19 deletions
diff --git a/src/lib/libcrypto/evp/e_ecb_r5.c b/src/lib/libcrypto/evp/e_ecb_r5.c index 08f4a82651..ef43ce34bf 100644 --- a/src/lib/libcrypto/evp/e_ecb_r5.c +++ b/src/lib/libcrypto/evp/e_ecb_r5.c | |||
@@ -60,19 +60,13 @@ | |||
60 | 60 | ||
61 | #include <stdio.h> | 61 | #include <stdio.h> |
62 | #include "cryptlib.h" | 62 | #include "cryptlib.h" |
63 | #include "evp.h" | 63 | #include <openssl/evp.h> |
64 | #include "objects.h" | 64 | #include <openssl/objects.h> |
65 | 65 | ||
66 | #ifndef NOPROTO | ||
67 | static void rc5_32_12_16_ecb_init_key(EVP_CIPHER_CTX *ctx, unsigned char *key, | 66 | static void rc5_32_12_16_ecb_init_key(EVP_CIPHER_CTX *ctx, unsigned char *key, |
68 | unsigned char *iv,int enc); | 67 | unsigned char *iv,int enc); |
69 | static void rc5_32_12_16_ecb_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, | 68 | static void rc5_32_12_16_ecb_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, |
70 | unsigned char *in, unsigned int inl); | 69 | unsigned char *in, unsigned int inl); |
71 | #else | ||
72 | static void rc5_32_12_16_ecb_init_key(); | ||
73 | static void rc5_32_12_16_ecb_cipher(); | ||
74 | #endif | ||
75 | |||
76 | static EVP_CIPHER rc5_ecb_cipher= | 70 | static EVP_CIPHER rc5_ecb_cipher= |
77 | { | 71 | { |
78 | NID_rc5_ecb, | 72 | NID_rc5_ecb, |
@@ -86,27 +80,21 @@ static EVP_CIPHER rc5_ecb_cipher= | |||
86 | NULL, | 80 | NULL, |
87 | }; | 81 | }; |
88 | 82 | ||
89 | EVP_CIPHER *EVP_rc5_32_12_16_ecb() | 83 | EVP_CIPHER *EVP_rc5_32_12_16_ecb(void) |
90 | { | 84 | { |
91 | return(&rc5_ecb_cipher); | 85 | return(&rc5_ecb_cipher); |
92 | } | 86 | } |
93 | 87 | ||
94 | static void rc5_32_12_16_ecb_init_key(ctx,key,iv,enc) | 88 | static void rc5_32_12_16_ecb_init_key(EVP_CIPHER_CTX *ctx, unsigned char *key, |
95 | EVP_CIPHER_CTX *ctx; | 89 | unsigned char *iv, int enc) |
96 | unsigned char *key; | ||
97 | unsigned char *iv; | ||
98 | int enc; | ||
99 | { | 90 | { |
100 | if (key != NULL) | 91 | if (key != NULL) |
101 | RC5_32_set_key(&(ctx->c.rc5_ks),EVP_RC5_32_12_16_KEY_SIZE,key, | 92 | RC5_32_set_key(&(ctx->c.rc5_ks),EVP_RC5_32_12_16_KEY_SIZE,key, |
102 | RC5_12_ROUNDS); | 93 | RC5_12_ROUNDS); |
103 | } | 94 | } |
104 | 95 | ||
105 | static void rc5_32_12_16_ecb_cipher(ctx,out,in,inl) | 96 | static void rc5_32_12_16_ecb_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, |
106 | EVP_CIPHER_CTX *ctx; | 97 | unsigned char *in, unsigned int inl) |
107 | unsigned char *out; | ||
108 | unsigned char *in; | ||
109 | unsigned int inl; | ||
110 | { | 98 | { |
111 | unsigned int i; | 99 | unsigned int i; |
112 | 100 | ||