make miscchecks

This commit is contained in:
iceman1001 2024-02-17 14:47:49 +01:00
parent 6466ce4e6d
commit b910d7ea94
4 changed files with 34 additions and 34 deletions

View file

@ -519,14 +519,14 @@ if (LZ4_FOUND)
endif (LZ4_FOUND)
if (NOT SKIPGD EQUAL 1 AND GD_FOUND)
set(ADDITIONAL_DIRS ${GD_INCLUDE_DIRS} ${ADDITIONAL_DIRS})
set(ADDITIONAL_LNK ${GD_LIBRARIES} ${ADDITIONAL_LNK})
set(ADDITIONAL_LNKDIRS ${GD_LIBRARY_DIRS} ${ADDITIONAL_LNKDIRS})
set(TARGET_SOURCES
${PM3_ROOT}/client/src/imgutils.c
${PM3_ROOT}/client/src/cmdhfwaveshare.c
${TARGET_SOURCES})
add_definitions("-DHAVE_GD")
set(ADDITIONAL_DIRS ${GD_INCLUDE_DIRS} ${ADDITIONAL_DIRS})
set(ADDITIONAL_LNK ${GD_LIBRARIES} ${ADDITIONAL_LNK})
set(ADDITIONAL_LNKDIRS ${GD_LIBRARY_DIRS} ${ADDITIONAL_LNKDIRS})
set(TARGET_SOURCES
${PM3_ROOT}/client/src/imgutils.c
${PM3_ROOT}/client/src/cmdhfwaveshare.c
${TARGET_SOURCES})
add_definitions("-DHAVE_GD")
endif (NOT SKIPGD EQUAL 1 AND GD_FOUND)
if (WHEREAMI_FOUND)

View file

@ -518,14 +518,14 @@ if (LZ4_FOUND)
endif (LZ4_FOUND)
if (NOT SKIPGD EQUAL 1 AND GD_FOUND)
set(ADDITIONAL_DIRS ${GD_INCLUDE_DIRS} ${ADDITIONAL_DIRS})
set(ADDITIONAL_LNK ${GD_LIBRARIES} ${ADDITIONAL_LNK})
set(ADDITIONAL_LNKDIRS ${GD_LIBRARY_DIRS} ${ADDITIONAL_LNKDIRS})
set(TARGET_SOURCES
${PM3_ROOT}/client/src/imgutils.c
${PM3_ROOT}/client/src/cmdhfwaveshare.c
${TARGET_SOURCES})
add_definitions("-DHAVE_GD")
set(ADDITIONAL_DIRS ${GD_INCLUDE_DIRS} ${ADDITIONAL_DIRS})
set(ADDITIONAL_LNK ${GD_LIBRARIES} ${ADDITIONAL_LNK})
set(ADDITIONAL_LNKDIRS ${GD_LIBRARY_DIRS} ${ADDITIONAL_LNKDIRS})
set(TARGET_SOURCES
${PM3_ROOT}/client/src/imgutils.c
${PM3_ROOT}/client/src/cmdhfwaveshare.c
${TARGET_SOURCES})
add_definitions("-DHAVE_GD")
endif (NOT SKIPGD EQUAL 1 AND GD_FOUND)
if (WHEREAMI_FOUND)

View file

@ -3737,23 +3737,23 @@ static int CmdCryptography(const char *Cmd) {
if (type & 0x4) { // AES or DES?
if (type & 0x02) { // If we will calculate a MAC
/*PrintAndLogEx(INFO, "Called FeliCa MAC");
// For DES all I know useful is the felica and fudan MAC algorithm.This is just des-cbc, but felica needs it in its way.
for (int i = 0; i < datilen; i+=8){ // For all 8 byte sequences
reverser(dati, &dati[i], 8, i);
if (i){ // If IV is processed
for (int n = 0; n < 8; ++n){
dato[n] ^= dati[i+n]; // XOR with Dx
}
des_encrypt_ecb(dato, dato, 8, key); // Cipher itself
} else { // If we didn't start with IV
for (int n = 0; n < 8; ++n){
dato[n] = iv[n]; // Feed data into output
dato[n] ^= dati[i+n]; // XOR with D1
}
des_encrypt_ecb(dato, dato, 8, key); // Cipher itself
}
}
PrintAndLogEx(SUCCESS, "MAC: %s", sprint_hex_inrow(dato, 8));*/
// For DES all I know useful is the felica and fudan MAC algorithm.This is just des-cbc, but felica needs it in its way.
for (int i = 0; i < datilen; i+=8){ // For all 8 byte sequences
reverser(dati, &dati[i], 8, i);
if (i){ // If IV is processed
for (int n = 0; n < 8; ++n){
dato[n] ^= dati[i+n]; // XOR with Dx
}
des_encrypt_ecb(dato, dato, 8, key); // Cipher itself
} else { // If we didn't start with IV
for (int n = 0; n < 8; ++n){
dato[n] = iv[n]; // Feed data into output
dato[n] ^= dati[i+n]; // XOR with D1
}
des_encrypt_ecb(dato, dato, 8, key); // Cipher itself
}
}
PrintAndLogEx(SUCCESS, "MAC: %s", sprint_hex_inrow(dato, 8));*/
PrintAndLogEx(INFO, "Not implemented yet - feel free to contribute!");
return PM3_SUCCESS;
} else {

View file

@ -1364,7 +1364,7 @@ static int CmdPCSC(const char *Cmd) {
}
if (cl_proto == ISODEP_NFCB) {
if (exchange_14b_apdu(cmdbuf + 2, apduLen, !field_activated, true, apduRes, sizeof(apduRes), &apduResLen, 0)) {
if (exchange_14b_apdu(cmdbuf + 2, apduLen, !field_activated, true, apduRes, sizeof(apduRes), &apduResLen, 0)) {
have_card = false;
mbedtls_net_close(&netCtx);
continue;