summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/des/fcrypt.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/libcrypto/des/fcrypt.c')
-rw-r--r--src/lib/libcrypto/des/fcrypt.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/lib/libcrypto/des/fcrypt.c b/src/lib/libcrypto/des/fcrypt.c
index f36746b376..fa1b8aa34a 100644
--- a/src/lib/libcrypto/des/fcrypt.c
+++ b/src/lib/libcrypto/des/fcrypt.c
@@ -1,7 +1,7 @@
1/* NOCW */ 1/* NOCW */
2#include <stdio.h> 2#include <stdio.h>
3 3
4/* This version of crypt has been developed from my MIT compatable 4/* This version of crypt has been developed from my MIT compatible
5 * DES library. 5 * DES library.
6 * The library is available at pub/Crypto/DES at ftp.psy.uq.oz.au 6 * The library is available at pub/Crypto/DES at ftp.psy.uq.oz.au
7 * Eric Young (eay@cryptsoft.com) 7 * Eric Young (eay@cryptsoft.com)
@@ -11,7 +11,7 @@
11 * I have included directive PARA for shared memory computers. 11 * I have included directive PARA for shared memory computers.
12 * I have included a directive LONGCRYPT to using this routine to cipher 12 * I have included a directive LONGCRYPT to using this routine to cipher
13 * passwords with more then 8 bytes like HP-UX 10.x it used. The MAXPLEN 13 * passwords with more then 8 bytes like HP-UX 10.x it used. The MAXPLEN
14 * definition is the maximum of lenght of password and can changed. I have 14 * definition is the maximum of length of password and can changed. I have
15 * defined 24. 15 * defined 24.
16 */ 16 */
17 17
@@ -103,8 +103,8 @@ char *ret;
103 * returns *\0XXXXXXXXX 103 * returns *\0XXXXXXXXX
104 * The \0 makes the string look like * so the pwd "*" would 104 * The \0 makes the string look like * so the pwd "*" would
105 * crypt to "*". This was found when replacing the crypt in 105 * crypt to "*". This was found when replacing the crypt in
106 * our shared libraries. People found that the disbled 106 * our shared libraries. People found that the disabled
107 * accounts effectivly had no passwd :-(. */ 107 * accounts effectively had no passwd :-(. */
108 x=ret[0]=((salt[0] == '\0')?'A':salt[0]); 108 x=ret[0]=((salt[0] == '\0')?'A':salt[0]);
109 Eswap0=con_salt[x]<<2; 109 Eswap0=con_salt[x]<<2;
110 x=ret[1]=((salt[1] == '\0')?'A':salt[1]); 110 x=ret[1]=((salt[1] == '\0')?'A':salt[1]);
@@ -123,7 +123,7 @@ r=(r+7)/8;
123 for (; i<8; i++) 123 for (; i<8; i++)
124 key[i]=0; 124 key[i]=0;
125 125
126 des_set_key((des_cblock *)(key),ks); 126 des_set_key_unchecked(&key,ks);
127 fcrypt_body(&(out[0]),ks,Eswap0,Eswap1); 127 fcrypt_body(&(out[0]),ks,Eswap0,Eswap1);
128 128
129 ll=out[0]; l2c(ll,b); 129 ll=out[0]; l2c(ll,b);