mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-04-02 10:30:16 +08:00
CHG: fixes to match the new arguments to the darkside attack (keytype A|B and blocknumber) in mifare_autopwn.lua script.
This commit is contained in:
parent
16658b1ff1
commit
b62cbadb61
1 changed files with 4 additions and 2 deletions
|
@ -28,6 +28,8 @@ Output files from this operation:
|
||||||
-- Some utilities
|
-- Some utilities
|
||||||
-------------------------------
|
-------------------------------
|
||||||
local DEBUG = false
|
local DEBUG = false
|
||||||
|
local MIFARE_AUTH_KEYA = 0x60
|
||||||
|
local MIFARE_AUTH_KEYB = 0x61
|
||||||
---
|
---
|
||||||
-- A debug printout-function
|
-- A debug printout-function
|
||||||
function dbg(args)
|
function dbg(args)
|
||||||
|
@ -66,7 +68,7 @@ end
|
||||||
function mfcrack()
|
function mfcrack()
|
||||||
core.clearCommandBuffer()
|
core.clearCommandBuffer()
|
||||||
-- Build the mifare-command
|
-- Build the mifare-command
|
||||||
local cmd = Command:new{cmd = cmds.CMD_READER_MIFARE, arg1 = 1, arg2 = 0}
|
local cmd = Command:new{cmd = cmds.CMD_READER_MIFARE, arg1 = 1, arg2 = 0, arg3 = MIFARE_AUTH_KEYA}
|
||||||
|
|
||||||
local retry = true
|
local retry = true
|
||||||
while retry do
|
while retry do
|
||||||
|
@ -78,7 +80,7 @@ function mfcrack()
|
||||||
if errormessage then return nil, errormessage end
|
if errormessage then return nil, errormessage end
|
||||||
-- Try again..set arg1 to 0 this time.
|
-- Try again..set arg1 to 0 this time.
|
||||||
|
|
||||||
cmd = Command:new{cmd = cmds.CMD_READER_MIFARE, arg1 = 0, arg2 = 0}
|
cmd = Command:new{cmd = cmds.CMD_READER_MIFARE, arg1 = 0, arg2 = 0, arg3 = MIFARE_AUTH_KEYA}
|
||||||
end
|
end
|
||||||
return nil, "Aborted by user"
|
return nil, "Aborted by user"
|
||||||
end
|
end
|
||||||
|
|
Loading…
Add table
Reference in a new issue