Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitaa51be1

Browse files
committed
piv: Fix detection of yubikey version
1 parent77819a3 commitaa51be1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

‎src/libopensc/card-piv.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5516,7 +5516,7 @@ static int piv_match_card_continued(sc_card_t *card)
55165516
apdu.resplen=sizeof(yubico_version_buf);
55175517
apdu.le=apdu.resplen;
55185518
r2=sc_transmit_apdu(card,&apdu);/* on error yubico_version == 0 */
5519-
if (r2>=3) {
5519+
if (r2==SC_SUCCESS&&apdu.resplen==3) {
55205520
priv->yubico_version= (yubico_version_buf[0]<<16) | (yubico_version_buf[1] <<8) |yubico_version_buf[2];
55215521
sc_log(card->ctx,"Yubico card->type=%d, r=0x%08x version=0x%08x",card->type,r,priv->yubico_version);
55225522
}

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp