=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/ssh/cipher.c,v retrieving revision 1.10 retrieving revision 1.11 diff -u -r1.10 -r1.11 --- src/usr.bin/ssh/cipher.c 1999/09/30 18:41:24 1.10 +++ src/usr.bin/ssh/cipher.c 1999/09/30 22:12:16 1.11 @@ -12,7 +12,7 @@ */ #include "includes.h" -RCSID("$Id: cipher.c,v 1.10 1999/09/30 18:41:24 provos Exp $"); +RCSID("$Id: cipher.c,v 1.11 1999/09/30 22:12:16 provos Exp $"); #include "ssh.h" #include "cipher.h" @@ -123,12 +123,12 @@ int cipher.h. */ static char *cipher_names[] = { - NULL, /* no none */ - NULL, /* no idea */ - NULL, /* no des */ + "none", + "idea", + "des", "3des", - NULL, /* no tss */ - NULL, /* no rc4 */ + "tss", + "rc4", "blowfish" }; @@ -163,7 +163,8 @@ { int i; for (i = 0; i < sizeof(cipher_names) / sizeof(cipher_names[0]); i++) - if (cipher_names[i] != NULL && strcmp(cipher_names[i], name) == 0) + if (strcmp(cipher_names[i], name) == 0 && + (cipher_mask() & (1 << i))) return i; return -1; }