diff options
author | djm <> | 2005-04-29 05:37:34 +0000 |
---|---|---|
committer | djm <> | 2005-04-29 05:37:34 +0000 |
commit | a95585a25ab25668b931a78b7543f707a3354db8 (patch) | |
tree | f9e9febf7ac0c8f5d6df761fe70fd613aac06203 /src/lib/libcrypto/rc4/rc4_skey.c | |
parent | 58c08aa241f168c84ce7cc3052454ea59a44eada (diff) | |
download | openbsd-a95585a25ab25668b931a78b7543f707a3354db8.tar.gz openbsd-a95585a25ab25668b931a78b7543f707a3354db8.tar.bz2 openbsd-a95585a25ab25668b931a78b7543f707a3354db8.zip |
import of openssl-0.9.7g; tested on platforms from alpha to zaurus, ok deraadt@
Diffstat (limited to 'src/lib/libcrypto/rc4/rc4_skey.c')
-rw-r--r-- | src/lib/libcrypto/rc4/rc4_skey.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/lib/libcrypto/rc4/rc4_skey.c b/src/lib/libcrypto/rc4/rc4_skey.c index bb10c1ebe2..07234f061a 100644 --- a/src/lib/libcrypto/rc4/rc4_skey.c +++ b/src/lib/libcrypto/rc4/rc4_skey.c | |||
@@ -57,6 +57,7 @@ | |||
57 | */ | 57 | */ |
58 | 58 | ||
59 | #include <openssl/rc4.h> | 59 | #include <openssl/rc4.h> |
60 | #include <openssl/crypto.h> | ||
60 | #include "rc4_locl.h" | 61 | #include "rc4_locl.h" |
61 | #include <openssl/opensslv.h> | 62 | #include <openssl/opensslv.h> |
62 | 63 | ||
@@ -85,7 +86,7 @@ const char *RC4_options(void) | |||
85 | * Date: Wed, 14 Sep 1994 06:35:31 GMT | 86 | * Date: Wed, 14 Sep 1994 06:35:31 GMT |
86 | */ | 87 | */ |
87 | 88 | ||
88 | void RC4_set_key(RC4_KEY *key, int len, const unsigned char *data) | 89 | FIPS_NON_FIPS_VCIPHER_Init(RC4) |
89 | { | 90 | { |
90 | register RC4_INT tmp; | 91 | register RC4_INT tmp; |
91 | register int id1,id2; | 92 | register int id1,id2; |
@@ -93,6 +94,11 @@ void RC4_set_key(RC4_KEY *key, int len, const unsigned char *data) | |||
93 | unsigned int i; | 94 | unsigned int i; |
94 | 95 | ||
95 | d= &(key->data[0]); | 96 | d= &(key->data[0]); |
97 | #if defined(__ia64) || defined(__ia64__) || defined(_M_IA64) | ||
98 | /* see crypto/rc4/asm/rc4-ia64.S for further details... */ | ||
99 | d=(RC4_INT *)(((size_t)(d+255))&~(sizeof(key->data)-1)); | ||
100 | #endif | ||
101 | |||
96 | for (i=0; i<256; i++) | 102 | for (i=0; i<256; i++) |
97 | d[i]=i; | 103 | d[i]=i; |
98 | key->x = 0; | 104 | key->x = 0; |