summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog4
-rw-r--r--scard-opensc.c6
2 files changed, 9 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 085b2b5bc..1e0509db0 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,8 @@
120030628 120030628
2 - (djm) Bug #591: use PKCS#15 private key label as a comment in case 2 - (djm) Bug #591: use PKCS#15 private key label as a comment in case
3 of OpenSC. Report and patch from larsch@trustcenter.de 3 of OpenSC. Report and patch from larsch@trustcenter.de
4 - (djm) Bug #593: Sanity check OpenSC card reader number; patch from
5 aj@dungeon.inka.de
4 6
520030628 720030628
6 - (dtucker) OpenBSD CVS Sync 8 - (dtucker) OpenBSD CVS Sync
@@ -607,4 +609,4 @@
607 - Fix sshd BindAddress and -b options for systems using fake-getaddrinfo. 609 - Fix sshd BindAddress and -b options for systems using fake-getaddrinfo.
608 Report from murple@murple.net, diagnosis from dtucker@zip.com.au 610 Report from murple@murple.net, diagnosis from dtucker@zip.com.au
609 611
610$Id: ChangeLog,v 1.2830 2003/06/28 08:02:47 djm Exp $ 612$Id: ChangeLog,v 1.2831 2003/06/28 08:08:16 djm Exp $
diff --git a/scard-opensc.c b/scard-opensc.c
index e8e12dd85..4ab87ea8a 100644
--- a/scard-opensc.c
+++ b/scard-opensc.c
@@ -89,6 +89,12 @@ sc_init(void)
89 r = sc_establish_context(&ctx, "openssh"); 89 r = sc_establish_context(&ctx, "openssh");
90 if (r) 90 if (r)
91 goto err; 91 goto err;
92 if (sc_reader_id >= ctx->reader_count) {
93 r = SC_ERROR_NO_READERS_FOUND;
94 error("Illegal reader number %d (max %d)", sc_reader_id,
95 ctx->reader_count -1);
96 goto err;
97 }
92 r = sc_connect_card(ctx->reader[sc_reader_id], 0, &card); 98 r = sc_connect_card(ctx->reader[sc_reader_id], 0, &card);
93 if (r) 99 if (r)
94 goto err; 100 goto err;