diff --git a/ChangeLog b/ChangeLog index 3b1f644c5..4db153d70 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,6 @@ +20010918 + - (djm) Configure support for smartcards + 20010917 - (djm) x11-ssh-askpass-1.2.4 in RPM spec, revert workarounds - (tim) [includes.h openbsd-compat/getopt.c openbsd-compat/getopt.h] @@ -6457,4 +6460,4 @@ - Wrote replacements for strlcpy and mkdtemp - Released 1.0pre1 -$Id: ChangeLog,v 1.1524 2001/09/17 21:34:33 tim Exp $ +$Id: ChangeLog,v 1.1525 2001/09/18 04:01:11 djm Exp $ diff --git a/acconfig.h b/acconfig.h index 76eb3a9e9..2b2be91ab 100644 --- a/acconfig.h +++ b/acconfig.h @@ -1,4 +1,4 @@ -/* $Id: acconfig.h,v 1.115 2001/09/15 11:31:54 djm Exp $ */ +/* $Id: acconfig.h,v 1.116 2001/09/18 04:01:12 djm Exp $ */ #ifndef _CONFIG_H #define _CONFIG_H @@ -333,6 +333,9 @@ /* Define on *nto-qnx systems */ #undef MISSING_FD_MASK +/* Define if you want smartcard support */ +#undef SMARTCARD + @BOTTOM@ /* ******************* Shouldn't need to edit below this line ************** */ diff --git a/configure.in b/configure.in index 30415d94a..d873054fa 100644 --- a/configure.in +++ b/configure.in @@ -1,4 +1,4 @@ -# $Id: configure.in,v 1.309 2001/09/17 21:34:34 tim Exp $ +# $Id: configure.in,v 1.310 2001/09/18 04:01:12 djm Exp $ AC_INIT(ssh.c) @@ -1310,13 +1310,42 @@ if test "x$ac_cv_libc_defines_sys_nerr" = "xyes" ; then fi +# Check whether user wants Kerberos support +SCARD_MSG="no" +AC_ARG_WITH(smartcard, + [ --with-smartcard Enable smartcard support], + [ + if test "x$withval" != "xno" ; then + if test "x$withval" != "xyes" ; then + CPPFLAGS="$CPPFLAGS -I${withval}" + LDFLAGS="$LDFLAGS -L${withval}" + if test ! -z "$need_dash_r" ; then + LDFLAGS="$LDFLAGS -R${withval}" + fi + if test ! -z "$blibpath" ; then + blibpath="$blibpath:${withval}" + fi + fi + AC_CHECK_HEADERS(sectok.h) + if test "$ac_cv_header_sectok_h" != yes; then + AC_MSG_ERROR(Can't find sectok.h) + fi + AC_CHECK_LIB(sectok, sectok_open) + if test "$ac_cv_lib_sectok_sectok_open" != yes; then + AC_MSG_ERROR(Can't find libsectok) + fi + AC_DEFINE(SMARTCARD) + SCARD_MSG="yes" + fi + ] +) + # Check whether user wants Kerberos support KRB4_MSG="no" AC_ARG_WITH(kerberos4, [ --with-kerberos4=PATH Enable Kerberos 4 support], [ if test "x$withval" != "xno" ; then - if test "x$withval" != "xyes" ; then CPPFLAGS="$CPPFLAGS -I${withval}/include" LDFLAGS="$LDFLAGS -L${withval}/lib" @@ -2069,6 +2098,7 @@ echo " Random number collection: $RAND_MSG" echo " Manpage format: $MANTYPE" echo " PAM support: ${PAM_MSG}" echo " KerberosIV support: $KRB4_MSG" +echo " Smartcard support: $SCARD_MSG" echo " AFS support: $AFS_MSG" echo " S/KEY support: $SKEY_MSG" echo " TCP Wrappers support: $TCPW_MSG" diff --git a/scard.c b/scard.c index 6e6de2f32..3a0288aaa 100644 --- a/scard.c +++ b/scard.c @@ -22,8 +22,8 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#ifdef SMARTCARD #include "includes.h" +#ifdef SMARTCARD RCSID("$OpenBSD: scard.c,v 1.13 2001/08/02 16:14:05 jakob Exp $"); #include