From f06b0ac5d36e0b8dd223a9658f7eb602fe0e1e7b Mon Sep 17 00:00:00 2001 From: Romain Tartiere Date: Sat, 18 Dec 2010 02:14:51 +0000 Subject: [PATCH] Ignore the status code when deciphering (3)DES data. --- libfreefare/mifare_desfire_authenticate.c | 1 + 1 file changed, 1 insertion(+) diff --git a/libfreefare/mifare_desfire_authenticate.c b/libfreefare/mifare_desfire_authenticate.c index 258500f..a1230fa 100644 --- a/libfreefare/mifare_desfire_authenticate.c +++ b/libfreefare/mifare_desfire_authenticate.c @@ -554,6 +554,7 @@ mifare_cryto_postprocess_data (MifareTag tag, void *data, ssize_t *nbytes, int c switch (key->type) { case T_DES: case T_3DES: + (*nbytes)--; mifare_cbc_des (MIFARE_DESFIRE (tag)->session_key, MIFARE_DESFIRE (tag)->ivect, res, *nbytes, MD_RECEIVE, 0); /*