diff --git a/CHANGELOG.md b/CHANGELOG.md index ff0985fd4..6e1c60b98 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,8 @@ This project uses the changelog in accordance with [keepchangelog](http://keepac ## [unreleased][unreleased] - Changed flash-stored key dictionaries (Mifare, iClass, T55XX) and T55XX configurations to SPIFFS files (@piotrva) +- Changed `lf em 410x sim` to use default gap value of 0 and extended help (@piotrva) +- Changed `hf 14a info` - now identifies MIAFRE Duox (@iceman1001) - Added `hf iclass trbl` to perform tear-off attacks on iClass (@antiklesys) - Added support for connection to host device in all Docker envs (@doegox) - Changed `hf 15 info` to show all type matches and check ST25TVxC signature (@doegox) diff --git a/client/src/cmdhf14a.c b/client/src/cmdhf14a.c index cd1db3e08..03e8585e1 100644 --- a/client/src/cmdhf14a.c +++ b/client/src/cmdhf14a.c @@ -1884,6 +1884,7 @@ static int detect_nxp_card_print(uint8_t sak, uint16_t atqa, uint64_t select_sta printTag("MIFARE DESFire EV2 2K/4K/8K/16K/32K"); printTag("MIFARE DESFire EV3 2K/4K/8K"); printTag("MIFARE DESFire Light 640B"); + printTag("MIFARE Duox"); type |= MTDESFIRE; } else { printTag("MIFARE Plus EV1 2K/4K CL2 in SL3"); diff --git a/client/src/cmdhfmfdes.c b/client/src/cmdhfmfdes.c index ee8b537c9..d0fcbf112 100644 --- a/client/src/cmdhfmfdes.c +++ b/client/src/cmdhfmfdes.c @@ -148,6 +148,7 @@ typedef enum { PLUS_EV2, NTAG413DNA, NTAG424, + DUOX, } nxp_cardtype_t; typedef enum { @@ -272,6 +273,10 @@ static char *getVersionStr(uint8_t type, uint8_t major, uint8_t minor) { snprintf(retStr, sizeof(buf), "%x.%x ( " _GREEN_("Plus EV1") " )", major, minor); else if (type == 0x02 && major == 0x22 && minor == 0x00) snprintf(retStr, sizeof(buf), "%x.%x ( " _GREEN_("Plus EV2") " )", major, minor); + else if (type == 0x01 && major == 0xA0 && minor == 0x00) + snprintf(retStr, sizeof(buf), "%x.%x ( " _GREEN_("DUOX") " )", major, minor); + else if ((type & 0x08) == 0x08) + snprintf(retStr, sizeof(buf), "%x.%x ( " _GREEN_("DESFire Light") " )", major, minor); else snprintf(retStr, sizeof(buf), "%x.%x ( " _YELLOW_("Unknown") " )", major, minor); return buf; @@ -338,6 +343,10 @@ static nxp_cardtype_t getCardType(uint8_t type, uint8_t major, uint8_t minor) { if (type == 0x01 && major == 0x33 && minor == 0x00) return DESFIRE_EV3; + // Duox + if (type == 0x01 && major == 0xA0 && minor == 0x00) + return DUOX; + // DESFire Light if (type == 0x08 && major == 0x30 && minor == 0x00) return DESFIRE_LIGHT; @@ -744,6 +753,8 @@ static int CmdHF14ADesInfo(const char *Cmd) { PrintAndLogEx(INFO, "\t2.2 - DESFire Ev2 XL, Originality check, proximity check, EAL5"); if (major == 3 && minor == 0) PrintAndLogEx(INFO, "\t3.0 - DESFire Ev3, Originality check, proximity check, badass EAL6 ?"); + if (major == 0xA0 && minor == 0) + PrintAndLogEx(INFO, "\tx.x - DUOX, Originality check, proximity check, EAL6++"); if (major == 0 && minor == 2) PrintAndLogEx(INFO, "\t0.2 - DESFire Light, Originality check, "); @@ -761,7 +772,8 @@ static int CmdHF14ADesInfo(const char *Cmd) { if (cardtype == DESFIRE_EV2 || cardtype == DESFIRE_EV2_XL || cardtype == DESFIRE_LIGHT || cardtype == DESFIRE_EV3 || - cardtype == NTAG413DNA) { + cardtype == NTAG413DNA || + cardtype == DUOX) { // Signature originality check uint8_t signature[250] = {0}; // must be 56 size_t signature_len = 0; diff --git a/client/src/cmdlfem410x.c b/client/src/cmdlfem410x.c index 10ad41369..5abbbd4d3 100644 --- a/client/src/cmdlfem410x.c +++ b/client/src/cmdlfem410x.c @@ -449,17 +449,19 @@ static int CmdEM410xSim(const char *Cmd) { CLIParserContext *ctx; CLIParserInit(&ctx, "lf em 410x sim", "Enables simulation of EM 410x card.\n" - "Simulation runs until the button is pressed or another USB command is issued.", + "Simulation runs until the button is pressed or another USB command is issued.\n" + "Most common readers expects the code to be sent in loop without a break (i.e. --gap 0).\n" + "For other, more advanced readers there might be a need to set a non-zero gap value.", "lf em 410x sim --id 0F0368568B\n" "lf em 410x sim --id 0F0368568B --clk 32\n" - "lf em 410x sim --id 0F0368568B --gap 0" + "lf em 410x sim --id 0F0368568B --gap 20" ); void *argtable[] = { arg_param_begin, arg_u64_0(NULL, "clk", "", "<32|64> clock (default 64)"), arg_str1(NULL, "id", "", "EM Tag ID number (5 hex bytes)"), - arg_u64_0(NULL, "gap", "", "gap (0's) between ID repeats (default 20)"), + arg_u64_0(NULL, "gap", "", "gap (0's) between ID repeats (default 0)"), arg_param_end }; CLIExecWithReturn(ctx, Cmd, argtable, false); @@ -467,7 +469,7 @@ static int CmdEM410xSim(const char *Cmd) { // clock is 64 in EM410x tags int clk = arg_get_u32_def(ctx, 1, 64); int uid_len = 0; - int gap = arg_get_u32_def(ctx, 3, 20); + int gap = arg_get_u32_def(ctx, 3, 0); uint8_t uid[5] = {0}; CLIGetHexWithReturn(ctx, 2, uid, &uid_len); CLIParserFree(ctx);