mirror of
https://github.com/Proxmark/proxmark3.git
synced 2025-08-19 21:03:23 -07:00
armsrc not compiled. fixed
This commit is contained in:
parent
64e60843cd
commit
5a367ac805
3 changed files with 15 additions and 13 deletions
|
@ -24,7 +24,8 @@ SRC_LF = lfops.c hitag2.c hitagS.c lfsampling.c pcf7931.c lfdemod.c protocols.c
|
|||
SRC_ISO15693 = iso15693.c iso15693tools.c
|
||||
SRC_ISO14443a = epa.c iso14443a.c mifareutil.c mifarecmd.c mifaresniff.c mifaresim.c
|
||||
SRC_ISO14443b = iso14443b.c
|
||||
SRC_CRAPTO1 = crypto1.c des.c
|
||||
SRC_CRAPTO1 = crypto1.c
|
||||
SRC_DES = des.c platform_util_arm.c
|
||||
SRC_CRC = iso14443crc.c crc.c crc16.c crc32.c parity.c
|
||||
SRC_SMARTCARD = i2c.c
|
||||
|
||||
|
@ -61,6 +62,7 @@ ARMSRC = fpgaloader.c \
|
|||
$(SRC_ISO14443a) \
|
||||
$(SRC_ISO14443b) \
|
||||
$(SRC_CRAPTO1) \
|
||||
$(SRC_DES) \
|
||||
$(SRC_CRC) \
|
||||
iclass.c \
|
||||
BigBuf.c \
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
#include "iso14443crc.h"
|
||||
#include "iso14443a.h"
|
||||
#include "crapto1/crapto1.h"
|
||||
#include "polarssl/des.h"
|
||||
#include "mbedtls/des.h"
|
||||
|
||||
int MF_DBGLEVEL = MF_DBG_ALL;
|
||||
|
||||
|
@ -296,7 +296,7 @@ int mifare_ultra_auth(uint8_t *keybytes){
|
|||
|
||||
/// 3des2k
|
||||
|
||||
des3_context ctx = { 0x00 };
|
||||
mbedtls_des3_context ctx = { 0x00 };
|
||||
uint8_t random_a[8] = {1,1,1,1,1,1,1,1};
|
||||
uint8_t random_b[8] = {0x00};
|
||||
uint8_t enc_random_b[8] = {0x00};
|
||||
|
@ -321,9 +321,9 @@ int mifare_ultra_auth(uint8_t *keybytes){
|
|||
|
||||
// decrypt nonce.
|
||||
// tdes_2key_dec(random_b, enc_random_b, sizeof(random_b), key, IV );
|
||||
des3_set2key_dec(&ctx, key);
|
||||
des3_crypt_cbc(&ctx // des3_context
|
||||
, DES_DECRYPT // int mode
|
||||
mbedtls_des3_set2key_dec(&ctx, key);
|
||||
mbedtls_des3_crypt_cbc(&ctx // des3_context
|
||||
, MBEDTLS_DES_DECRYPT // int mode
|
||||
, sizeof(random_b) // length
|
||||
, IV // iv[8]
|
||||
, enc_random_b // input
|
||||
|
@ -350,9 +350,9 @@ int mifare_ultra_auth(uint8_t *keybytes){
|
|||
|
||||
// encrypt out, in, length, key, iv
|
||||
//tdes_2key_enc(rnd_ab, rnd_ab, sizeof(rnd_ab), key, enc_random_b);
|
||||
des3_set2key_enc(&ctx, key);
|
||||
des3_crypt_cbc(&ctx // des3_context
|
||||
, DES_ENCRYPT // int mode
|
||||
mbedtls_des3_set2key_enc(&ctx, key);
|
||||
mbedtls_des3_crypt_cbc(&ctx // des3_context
|
||||
, MBEDTLS_DES_ENCRYPT // int mode
|
||||
, sizeof(rnd_ab) // length
|
||||
, enc_random_b // iv[8]
|
||||
, rnd_ab // input
|
||||
|
@ -372,9 +372,9 @@ int mifare_ultra_auth(uint8_t *keybytes){
|
|||
|
||||
// decrypt out, in, length, key, iv
|
||||
// tdes_2key_dec(resp_random_a, enc_resp, 8, key, enc_random_b);
|
||||
des3_set2key_dec(&ctx, key);
|
||||
des3_crypt_cbc(&ctx // des3_context
|
||||
, DES_DECRYPT // int mode
|
||||
mbedtls_des3_set2key_dec(&ctx, key);
|
||||
mbedtls_des3_crypt_cbc(&ctx // des3_context
|
||||
, MBEDTLS_DES_DECRYPT // int mode
|
||||
, 8 // length
|
||||
, enc_random_b // iv[8]
|
||||
, enc_resp // input
|
||||
|
|
|
@ -63,7 +63,7 @@ endif
|
|||
|
||||
|
||||
# Also search prerequisites in the common directory (for usb.c), the fpga directory (for fpga.bit), and the zlib directory
|
||||
VPATH = . ../common ../common/crapto1 ../common/polarssl ../fpga ../zlib
|
||||
VPATH = . ../common ../common/crapto1 ../common/mbedtls ../fpga ../zlib
|
||||
|
||||
INCLUDES = ../include/proxmark3.h ../include/at91sam7s512.h ../include/config_gpio.h ../include/usb_cmd.h $(APP_INCLUDES)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue