From: marshmellow42 Date: Tue, 13 Jun 2017 21:23:24 +0000 (-0400) Subject: Merge pull request #319 from Proxmark/iceman1001-patch-2 X-Git-Tag: v3.1.0~210 X-Git-Url: https://git.zerfleddert.de/cgi-bin/gitweb.cgi/proxmark3-svn/commitdiff_plain/e5a15888b6b0d8e9087082ece706e899ca60729d?hp=1e11e5d76208151660a58b67760a5276efc8ed58 Merge pull request #319 from Proxmark/iceman1001-patch-2 bug: hf mf chk - wrong size --- diff --git a/client/scripts/mfkeys.lua b/client/scripts/mfkeys.lua index 9471ad4b..c54f6e67 100644 --- a/client/scripts/mfkeys.lua +++ b/client/scripts/mfkeys.lua @@ -86,6 +86,7 @@ function checkBlock(blockNo, keys, keyType) -- The command data is only 512 bytes, each key is 6 bytes, meaning that we can send max 85 keys in one go. -- If there's more, we need to split it up local start, remaining= 1, #keys + local arg1 = bit32.bor(bit32.lshift(keyType, 8), blockNo) local packets = {} while remaining > 0 do local n,data = remaining, nil @@ -95,8 +96,8 @@ function checkBlock(blockNo, keys, keyType) --print("data len", #data) print(("Testing block %d, keytype %d, with %d keys"):format(blockNo, keyType, n)) local command = Command:new{cmd = cmds.CMD_MIFARE_CHKKEYS, - arg1 = blockNo, - arg2 = keyType, + arg1 = arg1, + arg2 = 1, arg3 = n, data = data} local status = checkCommand(command)