--- /dev/null
+// Merlok, 2011\r
+// people from mifare@nethemba.com, 2010\r
+//\r
+// This code is licensed to you under the terms of the GNU GPL, version 2 or,\r
+// at your option, any later version. See the LICENSE.txt file for the text of\r
+// the license.\r
+//-----------------------------------------------------------------------------\r
+// High frequency ISO14443A commands\r
+//-----------------------------------------------------------------------------\r
+\r
+#include <stdio.h>\r
+#include <stdlib.h>\r
+#include <unistd.h>\r
+#include <conio.h>\r
+#include "common.h"\r
+#include "cmdmain.h"\r
+#include "ui.h"\r
+#include "data.h"\r
+#include "proxusb.h"\r
+#include "util.h"\r
+#include "nonce2key/nonce2key.h"\r
+#include "nonce2key/crapto1.h"\r
+\r
+#define MEM_CHUNK 1000000\r
+#define NESTED_SECTOR_RETRY 10\r
+\r
+typedef struct fnVector { uint8_t blockNo, keyType; uint32_t uid, nt, ks1; } fnVector;\r
+\r
+typedef struct {\r
+ uint64_t Key[2];\r
+ int foundKey[2];\r
+} sector;\r
+ \r
+typedef struct {\r
+ uint64_t *possibleKeys;\r
+ uint32_t size;\r
+} pKeys;\r
+\r
+typedef struct {\r
+ uint64_t key;\r
+ int count;\r
+} countKeys;\r
+\r
+int mfnested(uint8_t blockNo, uint8_t keyType, uint8_t * key, uint8_t trgBlockNo, uint8_t trgKeyType, uint8_t * ResultKeys);\r
+int mfCheckKeys (uint8_t blockNo, uint8_t keyType, uint8_t keycnt, uint8_t * keyBlock, uint64_t * key);\r
+\r