]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
pcsc: Allow T1 protocol to be enabled
authorJouni Malinen <j@w1.fi>
Sun, 26 Feb 2012 11:14:46 +0000 (13:14 +0200)
committerJouni Malinen <j@w1.fi>
Sun, 26 Feb 2012 11:14:46 +0000 (13:14 +0200)
The previous implementation was hardcoding only T0 protocol to be
acceptable. Allow T1 to be selected, too.

Signed-hostap: Jouni Malinen <j@w1.fi>

src/utils/pcsc_funcs.c

index 4b43a3795aede34b447abc12de595aa1a4bc8ddc..d2f58e34ab2cb195fe35c9dfd202e33e00aec76a 100644 (file)
@@ -516,7 +516,8 @@ struct scard_data * scard_init(scard_sim_type sim_type, const char *reader)
 #endif /* UNICODE */
 
        ret = SCardConnect(scard->ctx, &readers[pos], SCARD_SHARE_SHARED,
-                          SCARD_PROTOCOL_T0, &scard->card, &scard->protocol);
+                          SCARD_PROTOCOL_T0 | SCARD_PROTOCOL_T1,
+                          &scard->card, &scard->protocol);
        if (ret != SCARD_S_SUCCESS) {
                if (ret == (long) SCARD_E_NO_SMARTCARD)
                        wpa_printf(MSG_INFO, "No smart card inserted.");