mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-21 13:53:55 -07:00
remove spurious spaces & tabs at end of lines
This commit is contained in:
parent
edc19f202a
commit
60f292b18e
249 changed files with 8481 additions and 8481 deletions
|
@ -82,11 +82,11 @@ bool nfc3d_amiibo_unpack(const nfc3d_amiibo_keys * amiiboKeys, const uint8_t * t
|
|||
nfc3d_amiibo_cipher(&dataKeys, internal, plain);
|
||||
|
||||
// Regenerate tag HMAC. Note: order matters, data HMAC depends on tag HMAC!
|
||||
mbedtls_md_hmac( mbedtls_md_info_from_type(MBEDTLS_MD_SHA256), tagKeys.hmacKey, sizeof(tagKeys.hmacKey),
|
||||
mbedtls_md_hmac( mbedtls_md_info_from_type(MBEDTLS_MD_SHA256), tagKeys.hmacKey, sizeof(tagKeys.hmacKey),
|
||||
plain + 0x1D4, 0x34, plain + HMAC_POS_TAG );
|
||||
|
||||
// Regenerate data HMAC
|
||||
mbedtls_md_hmac( mbedtls_md_info_from_type(MBEDTLS_MD_SHA256), dataKeys.hmacKey, sizeof(dataKeys.hmacKey),
|
||||
mbedtls_md_hmac( mbedtls_md_info_from_type(MBEDTLS_MD_SHA256), dataKeys.hmacKey, sizeof(dataKeys.hmacKey),
|
||||
plain + 0x029, 0x1DF, plain + HMAC_POS_DATA );
|
||||
|
||||
return
|
||||
|
@ -104,7 +104,7 @@ void nfc3d_amiibo_pack(const nfc3d_amiibo_keys * amiiboKeys, const uint8_t * pla
|
|||
nfc3d_amiibo_keygen(&amiiboKeys->data, plain, &dataKeys);
|
||||
|
||||
// Generate tag HMAC
|
||||
mbedtls_md_hmac( mbedtls_md_info_from_type(MBEDTLS_MD_SHA256), tagKeys.hmacKey, sizeof(tagKeys.hmacKey),
|
||||
mbedtls_md_hmac( mbedtls_md_info_from_type(MBEDTLS_MD_SHA256), tagKeys.hmacKey, sizeof(tagKeys.hmacKey),
|
||||
plain + 0x1D4, 0x34, cipher + HMAC_POS_TAG );
|
||||
|
||||
// Init mbedtls HMAC context
|
||||
|
@ -157,11 +157,11 @@ void nfc3d_amiibo_copy_app_data(const uint8_t * src, uint8_t * dst) {
|
|||
|
||||
//uint16_t *ami_nb_wr = (uint16_t*)(dst + 0x29);
|
||||
//uint16_t *cfg_nb_wr = (uint16_t*)(dst + 0xB4);
|
||||
|
||||
|
||||
/* increment write counters */
|
||||
//*ami_nb_wr = htobe16(be16toh(*ami_nb_wr) + 1);
|
||||
//*cfg_nb_wr = htobe16(be16toh(*cfg_nb_wr) + 1);
|
||||
|
||||
|
||||
uint16_t ami_nb_wr = ((uint16_t)bytes_to_num(dst + 0x29, 2)) + 1;
|
||||
uint16_t cfg_nb_wr = ((uint16_t)bytes_to_num(dst + 0xB4, 2)) + 1;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue