=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/ssh/Attic/scard.c,v retrieving revision 1.14.2.3 retrieving revision 1.15 diff -u -r1.14.2.3 -r1.15 --- src/usr.bin/ssh/Attic/scard.c 2002/03/08 17:04:42 1.14.2.3 +++ src/usr.bin/ssh/Attic/scard.c 2001/09/28 09:49:31 1.15 @@ -24,7 +24,7 @@ #ifdef SMARTCARD #include "includes.h" -RCSID("$OpenBSD: scard.c,v 1.14.2.3 2002/03/08 17:04:42 brad Exp $"); +RCSID("$OpenBSD: scard.c,v 1.15 2001/09/28 09:49:31 djm Exp $"); #include #include @@ -48,7 +48,7 @@ /* interface to libsectok */ -static int +static int sc_open(void) { int sw; @@ -79,7 +79,7 @@ return sc_fd; } -static int +static int sc_enable_applet(void) { static u_char aid[] = {0xfc, 0x53, 0x73, 0x68, 0x2e, 0x62, 0x69, 0x6e}; @@ -95,7 +95,7 @@ return 0; } -static int +static int sc_init(void) { int status; @@ -115,7 +115,7 @@ return 0; } -static int +static int sc_read_pubkey(Key * k) { u_char buf[2], *n; @@ -133,7 +133,7 @@ /* get key size */ sectok_apdu(sc_fd, CLA_SSH, INS_GET_KEYLENGTH, 0, 0, 0, NULL, - sizeof(buf), buf, &sw); + sizeof(buf), buf, &sw); if (!sectok_swOK(sw)) { error("could not obtain key length: %s", sectok_get_sw(sw)); goto err; @@ -204,7 +204,7 @@ goto err; } sectok_apdu(sc_fd, CLA_SSH, INS_GET_RESPONSE, 0, 0, 0, NULL, - len, padded, &sw); + len, padded, &sw); if (!sectok_swOK(sw)) { error("sc_private_decrypt: INS_GET_RESPONSE failed: %s", sectok_get_sw(sw)); @@ -249,7 +249,7 @@ goto err; } sectok_apdu(sc_fd, CLA_SSH, INS_GET_RESPONSE, 0, 0, 0, NULL, - len, to, &sw); + len, to, &sw); if (!sectok_swOK(sw)) { error("sc_private_decrypt: INS_GET_RESPONSE failed: %s", sectok_get_sw(sw)); @@ -320,8 +320,7 @@ smart_rsa.rsa_sign = def->rsa_sign; smart_rsa.rsa_verify = def->rsa_verify; - if ((smart_engine = ENGINE_new()) == NULL) - fatal("ENGINE_new failed"); + smart_engine = ENGINE_new(); ENGINE_set_id(smart_engine, "sectok"); ENGINE_set_name(smart_engine, "libsectok");