thanks to Abhisek Datta this nasty off-by-one bug could be fixed
authorMilosch Meriac <meriac@openpcd.de>
Wed, 2 May 2007 17:24:40 +0000 (17:24 +0000)
committerMilosch Meriac <meriac@openpcd.de>
Wed, 2 May 2007 17:24:40 +0000 (17:24 +0000)
git-svn-id: https://svn.gnumonks.org/trunk/librfid@1994 e0336214-984f-0b4b-a45f-81c69e1f0ede

utils/mifare-tool.c

index 58c0692..7c3a51e 100644 (file)
@@ -102,8 +102,7 @@ int main(int argc, char **argv)
        program_name = basename(argv[0]);
 #endif/*__MINGW32__*/
 
-       memcpy(key, MIFARE_CL_KEYA_DEFAULT_INFINEON,
-              sizeof(MIFARE_CL_KEYA_DEFAULT_INFINEON));
+       memcpy(key, MIFARE_CL_KEYA_DEFAULT_INFINEON, MIFARE_CL_KEY_LEN);
 
        printf("%s - (C) 2006 by Harald Welte\n"
               "This program is Free Software and has "