add: missing two hard_nested files..

This commit is contained in:
iceman1001
2015-12-02 16:48:25 +01:00
parent d08faa4e02
commit 8ce3e4b4e9
5 changed files with 1092 additions and 31 deletions

1058
client/cmdhfmfhard.c Normal file

File diff suppressed because it is too large Load Diff

11
client/cmdhfmfhard.h Normal file
View File

@@ -0,0 +1,11 @@
//-----------------------------------------------------------------------------
// Copyright (C) 2015 piwi
//
// This code is licensed to you under the terms of the GNU GPL, version 2 or,
// at your option, any later version. See the LICENSE.txt file for the text of
// the license.
//-----------------------------------------------------------------------------
// hf mf hardnested command
//-----------------------------------------------------------------------------
int mfnestedhard(uint8_t blockNo, uint8_t keyType, uint8_t * key, uint8_t trgBlockNo, uint8_t trgKeyType, bool nonce_file_read, bool nonce_file_write, bool slow);

View File

@@ -173,7 +173,7 @@ int CmdEM410xWrite(const char *Cmd)
{
uint64_t id = 0xFFFFFFFFFFFFFFFF; // invalid id value
int card = 0xFF; // invalid card value
unsigned int clock = 0; // invalid clock value
uint32_t clock = 0; // invalid clock value
sscanf(Cmd, "%" PRIx64 " %d %d", &id, &card, &clock);
@@ -199,8 +199,8 @@ int CmdEM410xWrite(const char *Cmd)
// Check Clock
// Default: 64
if (clock == 0)
clock = 64;
if (clock == 0)
clock = 64;
// Allowed clock rates: 16, 32, 40 and 64
if ((clock != 16) && (clock != 32) && (clock != 64) && (clock != 40)) {
@@ -225,7 +225,6 @@ int CmdEM410xWrite(const char *Cmd)
UsbCommand c = {CMD_EM410X_WRITE_TAG, {card, (uint32_t)(id >> 32), (uint32_t)id}};
SendCommand(&c);
return 0;
}