summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/rc2/rc2test.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/libcrypto/rc2/rc2test.c')
-rw-r--r--src/lib/libcrypto/rc2/rc2test.c27
1 files changed, 13 insertions, 14 deletions
diff --git a/src/lib/libcrypto/rc2/rc2test.c b/src/lib/libcrypto/rc2/rc2test.c
index 9d0f8016ec..6a5defa6ea 100644
--- a/src/lib/libcrypto/rc2/rc2test.c
+++ b/src/lib/libcrypto/rc2/rc2test.c
@@ -62,7 +62,15 @@
62#include <stdio.h> 62#include <stdio.h>
63#include <string.h> 63#include <string.h>
64#include <stdlib.h> 64#include <stdlib.h>
65#include "rc2.h" 65
66#ifdef NO_RC2
67int main(int argc, char *argv[])
68{
69 printf("No RC2 support\n");
70 return(0);
71}
72#else
73#include <openssl/rc2.h>
66 74
67unsigned char RC2key[4][16]={ 75unsigned char RC2key[4][16]={
68 {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, 76 {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
@@ -125,19 +133,11 @@ static unsigned char cfb_cipher64[CFB_TEST_SIZE]={
125 }; 133 };
126 134
127 135
128#ifndef NOPROTO
129/*static int cfb64_test(unsigned char *cfb_cipher);*/ 136/*static int cfb64_test(unsigned char *cfb_cipher);*/
130static char *pt(unsigned char *p); 137static char *pt(unsigned char *p);
131#else
132/*static int cfb64_test(); */
133static char *pt();
134#endif 138#endif
135 139
136#endif 140int main(int argc, char *argv[])
137
138int main(argc,argv)
139int argc;
140char *argv[];
141 { 141 {
142 int i,n,err=0; 142 int i,n,err=0;
143 RC2_KEY key; 143 RC2_KEY key;
@@ -208,8 +208,7 @@ char *argv[];
208 } 208 }
209 209
210#ifdef undef 210#ifdef undef
211static int cfb64_test(cfb_cipher) 211static int cfb64_test(unsigned char *cfb_cipher)
212unsigned char *cfb_cipher;
213 { 212 {
214 IDEA_KEY_SCHEDULE eks,dks; 213 IDEA_KEY_SCHEDULE eks,dks;
215 int err=0,i,n; 214 int err=0,i,n;
@@ -247,8 +246,7 @@ unsigned char *cfb_cipher;
247 return(err); 246 return(err);
248 } 247 }
249 248
250static char *pt(p) 249static char *pt(unsigned char *p)
251unsigned char *p;
252 { 250 {
253 static char bufs[10][20]; 251 static char bufs[10][20];
254 static int bnum=0; 252 static int bnum=0;
@@ -268,3 +266,4 @@ unsigned char *p;
268 } 266 }
269 267
270#endif 268#endif
269#endif