From e58080b7d20df6e1a6d2ae0f1cd118a1d80c28ee Mon Sep 17 00:00:00 2001 From: joernchen of Phenoelit Date: Sat, 18 Jan 2014 20:39:56 +0100 Subject: [PATCH] Bugfix: -Y should not work with -6 or -8 --- ykchalresp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ykchalresp.c b/ykchalresp.c index 370291f..ff81840 100644 --- a/ykchalresp.c +++ b/ykchalresp.c @@ -250,7 +250,7 @@ static int challenge_response(YK_KEY *yk, int slot, /* HMAC responses are 160 bits, Yubico 128 */ expect_bytes = (hmac == true) ? 20 : 16; - if(digits){ + if(digits && hmac){ offset = response[19] & 0xf ; bin_code = (response[offset] & 0x7f) << 24 | (response[offset+1] & 0xff) << 16 -- 2.39.5