projects
/
proxmark3-svn
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
CHG: Added the urls to the new Wiki on github inside the flasher.c usuage text.
[proxmark3-svn]
/
armsrc
/
desfire_crypto.c
diff --git
a/armsrc/desfire_crypto.c
b/armsrc/desfire_crypto.c
index 9ea07371f9d2fa84d5e13abfbbd304a2e84674e6..469a8ec46761a807978d376066269840a586a150 100644
(file)
--- a/
armsrc/desfire_crypto.c
+++ b/
armsrc/desfire_crypto.c
@@
-27,9
+27,8
@@
*/
#include "desfire_crypto.h"
*/
#include "desfire_crypto.h"
-static void xor (const uint8_t *ivect, uint8_t *data, const size_t len);
-
-static size_t key_macing_length (desfirekey_t key);
+static void xor (const uint8_t *ivect, uint8_t *data, const size_t len);
+static size_t key_macing_length (desfirekey_t key);
static void xor (const uint8_t *ivect, uint8_t *data, const size_t len) {
for (size_t i = 0; i < len; i++) {
static void xor (const uint8_t *ivect, uint8_t *data, const size_t len) {
for (size_t i = 0; i < len; i++) {
@@
-85,6
+84,7
@@
void cmac (const desfirekey_t key, uint8_t *ivect, const uint8_t *data, size_t l
mifare_cypher_blocks_chained (NULL, key, ivect, buffer, len, MCD_SEND, MCO_ENCYPHER);
memcpy (cmac, ivect, kbs);
mifare_cypher_blocks_chained (NULL, key, ivect, buffer, len, MCD_SEND, MCO_ENCYPHER);
memcpy (cmac, ivect, kbs);
+ free(buffer);
}
size_t key_block_size (const desfirekey_t key) {
}
size_t key_block_size (const desfirekey_t key) {
Impressum
,
Datenschutz