Commit graph

507 commits

Author SHA1 Message Date
merlokk 5858d1ffb3 coverity 2021-07-29 18:45:04 +03:00
merlokk 0ed35d3368 noauth refactoring 2021-07-29 18:34:54 +03:00
merlokk 2441b24124 make style 2021-07-29 18:19:59 +03:00
merlokk 9e24a78dc0 move code from old part 2021-07-29 17:38:11 +03:00
merlokk d3c1558411 remove old code 2021-07-29 17:26:34 +03:00
merlokk cd760e05e7 detailed print settings 2021-07-29 17:22:51 +03:00
merlokk d6f75fa427 remove old code + add verbosity 2021-07-29 16:58:56 +03:00
merlokk 7510fa3837 dump works 2021-07-29 16:42:07 +03:00
merlokk 985bcc9c4a commands read and lsfiles refactoring 2021-07-29 16:19:16 +03:00
merlokk 701390246d move command 2021-07-29 10:39:07 +03:00
merlokk 74fc92f1db works 2021-07-29 09:01:10 +03:00
merlokk a5f7e4172b formatting 2021-07-29 00:21:16 +03:00
merlokk 907c4a4b39 data ready 2021-07-29 00:00:38 +03:00
merlokk 29b955f45a lsfiles command 2021-07-28 23:17:26 +03:00
merlokk 192a82a682 cov 2021-07-28 22:48:48 +03:00
merlokk a011894542 update help 2021-07-28 19:28:55 +03:00
merlokk 317526f3fa remove old 2021-07-28 19:24:04 +03:00
merlokk cba4e3f90d update record works 2021-07-28 19:18:16 +03:00
merlokk 601597362d write record 2021-07-28 18:51:56 +03:00
merlokk 3c2542d58b add some help, fix commit logic 2021-07-28 18:37:22 +03:00
merlokk 896aeefd9a move commit phase outside 2021-07-28 18:24:50 +03:00
merlokk f5d5f088b8 write file command 2021-07-28 18:13:07 +03:00
merlokk c098c496eb coverity 353982 353927 2021-07-28 16:37:04 +03:00
merlokk b508ca3e5d d40/mac mode works in mac and plain modes 2021-07-28 15:27:22 +03:00
merlokk b1f819e208 d40/encoded channel works 2021-07-28 14:18:53 +03:00
merlokk 6f2bc725ca fix help 2021-07-28 00:15:14 +03:00
merlokk 774d60fa83 fix text 2021-07-28 00:10:51 +03:00
merlokk 17944f7d0a auto read file improvement 2021-07-28 00:07:18 +03:00
merlokk 8910fbac6f autodetect file type 2021-07-27 21:24:51 +03:00
merlokk 5a7e507de2 advanced record reading 2021-07-27 20:00:18 +03:00
merlokk 882e96a3ce remove old 2021-07-27 19:20:30 +03:00
merlokk 6481142b41 cov 353927 2021-07-27 19:17:52 +03:00
merlokk edb09c4d01 cov 353974 2021-07-27 19:17:03 +03:00
merlokk 2ac2e7dcf9 add records and mac to command 2021-07-27 19:13:51 +03:00
merlokk 7d8009a32b move print buffer to util 2021-07-27 17:51:27 +03:00
merlokk 8f9e3977d4 read interface. read value works 2021-07-27 16:54:28 +03:00
merlokk 7e2fd2a953 move functions 2021-07-27 15:37:30 +03:00
merlokk d22817f8cc create file works. fixed consts, mode and samples 2021-07-27 14:51:31 +03:00
merlokk efa91d4b00 command 2021-07-27 13:11:12 +03:00
merlokk f5397cbfe0 fix order 2021-07-26 22:54:05 +03:00
merlokk 8ff7ad9a87 chfileparams refactoring 2021-07-26 20:22:08 +03:00
merlokk a5f18cc58b clear record file 2021-07-26 19:45:37 +03:00
merlokk 831dafc456 more verbosity 2021-07-26 19:33:40 +03:00
merlokk 4356cf1151 remove old code 2021-07-26 19:26:20 +03:00
merlokk 2a5a6fde81 cov 353969 353968 353927 353930 2021-07-26 19:21:39 +03:00
merlokk 062cf98166 cov 353970 and rename 2021-07-26 19:15:54 +03:00
merlokk c44d7728b4 fix help 2021-07-26 19:12:47 +03:00
merlokk fab6d5748c create record file command 2021-07-26 18:39:52 +03:00
merlokk 73f62ae27e make style 2021-07-26 18:00:15 +03:00
merlokk 8077f6229c cov 353930 353966 etc 2021-07-26 17:41:26 +03:00
merlokk eb69219a27 cov 353929 2021-07-26 17:37:41 +03:00
merlokk dd3798c230 cov 353927 2021-07-26 17:36:23 +03:00
merlokk 5ca3d2abca cov 353926 2021-07-26 17:34:55 +03:00
merlokk b67f72253f fix help 2021-07-26 17:31:30 +03:00
merlokk 4fc4ae7ab8 remove some code 2021-07-26 17:28:06 +03:00
merlokk 414ad304cd clear works 2021-07-26 17:12:48 +03:00
merlokk bdb067dd4c credit/debit works 2021-07-26 16:45:38 +03:00
merlokk 1adfc0a931 get value works 2021-07-26 16:35:45 +03:00
merlokk 997234e18d add create file to channel tables, remove debug 2021-07-26 14:15:11 +03:00
merlokk 64b3dcc2e2 create value file works 2021-07-26 13:59:13 +03:00
merlokk 146cc32c62 value file fixes 2021-07-25 20:03:48 +03:00
merlokk e0a5a47886 cov 351154 2021-07-25 11:58:49 +03:00
merlokk 4444fb4533 refactoring fix 2021-07-24 00:52:54 +03:00
merlokk 40227edd7e refactoring and create value file command sketch 2021-07-23 20:50:23 +03:00
merlokk 68ebc84641 remove old 2021-07-23 18:42:27 +03:00
merlokk 8674a5ef18 create file all modes works 2021-07-23 18:37:11 +03:00
merlokk 012e90f5c8 create file raw mode works 2021-07-23 17:03:48 +03:00
merlokk 606c4a2ecd more rights refactoring 2021-07-23 13:35:30 +03:00
merlokk bbf7b1a26d file settings refactoring and fix bug in get file ids 2021-07-23 13:16:51 +03:00
merlokk dcd018f3aa fix mode 2021-07-22 21:21:16 +03:00
merlokk 325e304e41 delete file command 2021-07-22 21:16:42 +03:00
merlokk e82f2e1efb text fix 2021-07-21 23:23:10 +03:00
merlokk 00368aa994 added check mode for change file settings 2021-07-21 23:18:43 +03:00
merlokk 07d753dfea added no-auth 2021-07-21 21:53:21 +03:00
merlokk 15d97112aa chfilesettings client command 2021-07-21 18:11:15 +03:00
merlokk e93291e61d remove todo 2021-07-21 15:51:36 +03:00
merlokk f6e86293f0 print file settings. move from old code. 2021-07-21 15:50:26 +03:00
merlokk 408fc64e55 get file settings command 2021-07-21 09:21:57 +03:00
merlokk 0c4d7cfbbe add iso file id list command 2021-07-21 08:39:46 +03:00
merlokk 66a9e80bd7 add getfileids 2021-07-21 08:29:57 +03:00
merlokk 10362d68cf make style 2021-07-20 21:20:55 +03:00
merlokk a074b1f812 remove todo 2021-07-20 21:11:32 +03:00
merlokk 2f1611a7cf text + remove debug 2021-07-20 21:10:42 +03:00
merlokk b062ffa6cd set config works 2021-07-20 21:07:31 +03:00
merlokk 61ffdb5269 add set config command and some verbosity 2021-07-20 13:58:05 +03:00
merlokk b415ee086d remove double padding 2021-07-19 19:54:51 +03:00
merlokk b6a65405a0 remove debug 2021-07-19 19:05:07 +03:00
merlokk d50c72b30e fix create app defaults 2021-07-19 18:40:24 +03:00
merlokk 449f4edcb0 restrict change key algo 2021-07-19 18:32:10 +03:00
merlokk 31334da0c4 fix key type defsults 2021-07-19 09:38:32 +03:00
merlokk 6a6ec86791 fix 2tdea/d40 authentication 2021-07-16 20:45:32 +03:00
merlokk cf63b9e022 make style 2021-07-16 20:11:41 +03:00
merlokk bdac4cb48d print the new key if we put the key version into the des key 2021-07-16 20:05:14 +03:00
merlokk a35e185b5b add setup oldkey if we change the same key 2021-07-16 19:57:11 +03:00
merlokk bbc4f378ab some info 2021-07-15 20:41:34 +03:00
merlokk 46a294d585 core works 2021-07-15 20:14:02 +03:00
merlokk 92a0639ba8 fix 2021-07-15 15:26:25 +03:00
merlokk 1317fa8e32 command renamings, remove code 2021-07-13 18:42:03 +03:00
merlokk bd96dc4844 small fixes 2021-07-13 18:36:07 +03:00
merlokk 480bd87207 make style 2021-07-13 18:20:22 +03:00
merlokk 1b3e34c928 createapp fully works 2021-07-13 18:13:29 +03:00
merlokk 2f2942c7db CmdHF14ADesGetAppNames --no-auth 2021-07-13 17:42:10 +03:00
merlokk 741f560a8d hf mfdes getaids -- no-auth 2021-07-13 17:29:45 +03:00
merlokk 668650b8cd fix bugs 2021-07-13 17:23:29 +03:00
merlokk 9b70ebc01f fix cmd default test 2021-07-13 16:56:28 +03:00
merlokk e00fc93c20 createfile works 2021-07-13 16:51:50 +03:00
merlokk 7ce5fa53f4 createapp help and textual changes 2021-07-13 14:56:56 +03:00
merlokk 9fe785f918 remove code 2021-07-13 13:34:35 +03:00
merlokk 2505b17912 delete aid ok 2021-07-13 13:32:38 +03:00
merlokk 3e86c15a33 cov 351017 2021-07-13 12:16:30 +03:00
merlokk d4646ce6d6 add aid to formatpicc 2021-07-12 23:53:57 +03:00
merlokk 12969cf728 text 2021-07-12 23:36:25 +03:00
merlokk cf96dc3acb get free mem an format icc commands 2021-07-12 23:33:13 +03:00
merlokk 6f66a97cb3 help text 2021-07-12 21:50:02 +03:00
merlokk 90fe298b33 remove todo that is done 2021-07-12 19:28:29 +03:00
merlokk 7bff67dceb new getuid works 2021-07-12 19:27:24 +03:00
merlokk 5bca74e5c8 DropField 2021-07-12 19:12:47 +03:00
merlokk 10409c3fdc help text 2021-07-12 18:56:30 +03:00
merlokk 81740b3494 cov 350889 2021-07-12 18:47:26 +03:00
merlokk 9c320dc241 getkeyversion works 2021-07-12 18:45:59 +03:00
merlokk 55b6ff8e05 make select-and-authenticate function 2021-07-12 17:53:17 +03:00
merlokk 2d5cc6aec7 350889 2021-07-12 11:21:48 +03:00
merlokk 72ef378cd1 350888 2021-07-12 11:20:50 +03:00
merlokk a0ec56cdc4 350557 2021-07-12 11:15:50 +03:00
merlokk 88e573d072 add default channel settings to commands 2021-07-11 18:58:26 +03:00
merlokk d8a8c015bc channel d40/encode works 2021-07-11 18:14:27 +03:00
merlokk 3f7f343f6f DesfireChangeKeySettings works 2021-07-10 16:11:44 +03:00
merlokk 5367cb4e23 CmdHF14ADesChKeySettings command 2021-07-10 16:05:40 +03:00
merlokk 1cd467e1f3 change param name 2021-07-10 15:16:06 +03:00
merlokk b6e6070bfe remove debug 2021-07-10 15:08:39 +03:00
merlokk 67d7d29d74 CmdHF14ADesGetKeySettings works 2021-07-10 15:07:51 +03:00
merlokk c8777ebea8 add getkeysettings command 2021-07-09 19:26:41 +03:00
merlokk d67ea92e2e implement check channel, add 2 new commands 2021-07-09 18:04:27 +03:00
merlokk aa1d98ba55 fix test AlwaysAvailable 2021-07-09 16:06:18 +03:00
merlokk fff1c8fae1 add test command and crc tests 2021-07-09 15:15:16 +03:00
merlokk 6e207be3ac added there is no applications message if it there is no app) 2021-07-07 16:31:23 +03:00
merlokk 20696fb44a make style 2021-07-06 12:16:19 +03:00
merlokk b63a991bc3 fix coverity 350561 2021-07-05 19:04:41 +03:00
merlokk 7882a2dbaa fix coverity 350557 2021-07-05 19:03:41 +03:00
merlokk be9db18852 fix coverity 350572 2021-07-05 15:22:33 +03:00
merlokk d6dc117ed3 mark commands with new sign 2021-07-05 14:18:05 +03:00
merlokk e9b8e18430 remove key_size 2021-07-05 14:15:39 +03:00
merlokk 003a0b0de4 splitbysize now put length of message at the first bytes of array's memory 2021-07-05 12:40:07 +03:00
merlokk 6124b49c99 DesfirePrintContext prints session state 2021-07-04 12:47:09 +03:00
merlokk 5271cb96c3 add commant, remove debug 2021-07-04 12:25:34 +03:00
merlokk 2abd930ef7 simplify cliparser optinlist. added mfdes default 2021-07-04 12:20:09 +03:00
merlokk 1b2442ec36 regactoring desfire commands. textual fixes 2021-07-03 17:31:12 +03:00
merlokk 0d00f56777 CmdHF14ADesGetAppNames works 2021-07-03 13:11:17 +03:00
merlokk f9e006f2e3 added authchann otion 2021-07-03 12:21:29 +03:00
merlokk acca624752 added cli text options to command 2021-07-03 00:08:45 +03:00
merlokk 0aad993711 remove comments and text fixes 2021-07-02 18:17:21 +03:00
merlokk 636a1dd457 DesfireGetAIDList works 2021-07-02 18:06:13 +03:00
merlokk e5d24ff81f authentication works 2021-07-02 17:37:15 +03:00
merlokk b5ee999c73 rename GetErrorString -> DesfireGetErrorString 2021-07-01 20:47:02 +03:00
merlokk 73db86bcc7 exchange returns result. select works 2021-07-01 20:32:04 +03:00
merlokk ecfcc21ded select works (somehow) 2021-07-01 20:06:33 +03:00
merlokk 2fa6c4643e desfire channel sketch 2021-07-01 19:53:57 +03:00
iceman1001 e2ca0a4abd style 2021-06-24 18:47:11 +02:00
mwalker33 1655cdd206 Update cmdhfmfdes.c
Remove old code
2021-06-22 17:22:01 +10:00
mwalker33 69e1afbda9 Update cmdhfmfdes.c
Coverity : 320356, 286670, 344402
2021-06-22 17:15:04 +10:00
iceman1001 9d02c2e94a renamed 'hf mfdes readdata, writedata' to 'read/write' 2021-06-20 16:37:51 +02:00
iceman1001 861e06d8af fix coverity CID 322780 - out-of-bounds 2021-06-20 10:47:23 +02:00
iceman1001 e8d5d81178 code style, and make less output for hf search 2021-06-20 10:41:47 +02:00
iceman1001 2f432788cf fix out-of-bounds access 2021-06-20 07:49:41 +02:00
mwalker33 57729b604c Update cmdhfmfdes.c
realloc update
2021-06-19 13:12:10 +10:00
mwalker33 094f9edbad
Merge branch 'master' into desfire 2021-06-19 11:10:20 +10:00
mwalker33 22d311e5fa Update cmdhfmfdes.c
3K3Des Authentication and Change Key patch
Get Card UID (when authenticated for real UID
3Des session key patch when 1st half = 2nd Half
2021-06-19 11:05:59 +10:00
Philippe Teuwen af6ff40748 simplify Iso7816Connect 2021-06-04 21:58:38 +02:00
Philippe Teuwen 11334f9440 Isolate ISO7816 select & exchange from EMVcore 2021-06-04 21:58:38 +02:00
Philippe Teuwen 4c44138557 make style 2021-05-30 14:29:05 +02:00
Philippe Teuwen 323c391f4d nfc commands 2021-05-30 14:23:13 +02:00
iceman1001 9a9d86de95 text 2021-05-22 14:20:38 +02:00
iceman1001 326d2cf5d3 resplen is a pointer and we want its value 2021-05-22 07:36:14 +02:00
iceman1001 6a6dcd4f56 fix cppchecker 2021-05-21 21:07:38 +02:00
iceman1001 51fb73f4c8 cppchecker fixes 2021-05-21 11:49:00 +02:00
iceman1001 0d017908b4 style 2021-05-20 10:31:21 +02:00
iceman1001 b9bf84dbf1 desfire readdata fct, now deals with both INS cases 2021-05-20 10:15:16 +02:00
iceman1001 d46f80e7ea new desfire ats, based on #PR138 in nfc-tools/libfreefare repository 2021-05-20 06:44:48 +02:00
iceman1001 a0efc7aa02 Merge branch 'master' of github.com:RfidResearchGroup/proxmark3 2021-05-19 18:07:29 +02:00
iceman1001 8bf5a99bca codestyle prefer calloc 2021-05-19 18:07:19 +02:00
Iceman a469fdd24b
Merge pull request #1279 from mwalker33/desfire
Update cmdhfmfdes.c
2021-05-19 12:58:07 +02:00
mwalker33 0c71b6cc32 Update cmdhfmfdes.c
use defines for command 0xc4
2021-05-19 20:57:06 +10:00
mwalker33 c731c945d6 Update cmdhfmfdes.c
Desfire
- Change Key where key to change = key used to authenticate
- Patch to stop an AES key change incorrectly reporting an issue
2021-05-19 20:47:11 +10:00
Philippe Teuwen a592b349cb make style 2021-05-18 23:56:11 +02:00
mwalker33 e0269bde74 Update cmdhfmfdes.c
Desfire readdata patch
2021-05-18 19:49:03 +10:00
mwalker33 cfdef9e92e Update cmdhfmfdes.c
Desfire write MAC'ed and Encrypted update
2021-05-17 19:16:27 +10:00
mwalker33 af59e27643 Update cmdhfmfdes.c
WriteData - Fixed MACed calculation.
- Tested on Plain (free and Authenticated access)
- Authenticated Plain+MAC

Bugfix for write loop for correct data offset etc.
2021-05-16 16:52:53 +10:00
iceman1001 752a41e423 coverity CID 286923 2021-05-14 08:10:54 +02:00
iceman1001 5cc79c7dfd fix cppchecker 2021-05-13 22:40:13 +02:00
iceman1001 03e535ac67 fix cppchecker 2021-05-13 22:38:01 +02:00
iceman1001 4e48b10ab9 cppchecker fixes 2021-05-13 20:21:06 +02:00
iceman1001 5c64cc6adb fix coverity CID 322519 2021-05-13 17:00:37 +02:00
iceman1001 1ff1fa7385 style 2021-05-11 15:43:12 +02:00
iceman1001 f83fa37b86 fix so authenticated session works with reading a file 2021-05-11 15:37:05 +02:00
iceman1001 4853704920 text 2021-05-11 15:36:27 +02:00
iceman1001 e4f55556ba style 2021-05-05 21:04:48 +02:00
iceman1001 0d1f8ca957 making a 14a select fct reachable, in order to do a test in desfire code without repeating same ftc 2021-04-30 11:18:14 +02:00
iceman1001 550fa5aa8f 14a exchange apdu now uses defined return codes 2021-04-30 08:51:38 +02:00
mwalker33 ae42c9445a Update cmdhfmfdes.c
Desfire changekey AES
Seems to work, but response validation fails.
2021-04-24 13:43:00 +10:00
mwalker33 6780b852d4 Update cmdhfmfdes.c
Desfire DES/3DES change key works
2021-04-23 07:44:32 +10:00
iceman1001 c7e47a721d cliparser doesnt like empty strings, 2021-04-19 23:00:02 +02:00
Philippe Teuwen dc54dd305b Use CmdTraceListAlias everywhere 2021-04-19 21:43:32 +02:00
iceman1001 d46c90b231 text 2021-03-27 10:21:27 +01:00
iceman1001 b894365647 hf mfdes info - text 2021-03-17 10:44:30 +01:00
iceman1001 68033b8e2c hf mfdes info - text 2021-03-17 10:40:05 +01:00
iceman1001 bf62e47575 fix.... 2021-02-19 17:37:41 +01:00
iceman1001 f6b1cfd64c maur pk 2021-02-19 16:56:22 +01:00
Anže Jenšterle 8760068a03
make style 2021-02-09 16:52:48 +01:00
Anže Jenšterle cf8256979d
fix code per comments 2021-02-09 16:15:52 +01:00
Anže Jenšterle 8af1cedf1f
Improved MFDES AID bruteforce 2021-02-09 15:17:20 +01:00
Anže Jenšterle 6d10525c09
fixed missing parameter 2021-02-08 03:32:27 +01:00
Anže Jenšterle 99b1093702
Added actual MF DESfire enumeration 2021-02-08 01:12:14 +01:00
iceman1001 e96cfa94b6 hf mfdes getuid/info/eum - with a default cliparser 2021-01-07 11:40:10 +01:00
tcprst 1afb335478
make style 2020-11-22 19:39:54 -05:00
iceman1001 a11e2ed4a6 hf mfdes info - cmk textual ( #1062 ) 2020-11-22 23:42:00 +01:00
iceman1001 57eef7c5a9 hf mfdes.. a session flag to keep track of rf field up/down. Now selectaid/createaid/deleteaid works. However, hf mfdes auth is needed before. the rest of the commands needs to be adapted to this new style. The reason is that a "select application" command aborts a current authenticated session. So we need to authenticate and keep that on until we done. 2020-11-19 12:15:47 +01:00
iceman1001 4d28ffc014 hf mfdes deleteaid - shouldn't select before since it cancels the current session 2020-11-18 23:58:50 +01:00
iceman1001 4cafbcc259 hf mfdes - keeping track in the tag object of rf_field active status 2020-11-18 23:47:54 +01:00
iceman1001 1ae89950eb dbg printing 2020-11-14 12:40:59 +01:00
iceman1001 243d509203 remove dump.c step2 2020-11-12 18:43:03 +01:00
iceman1001 089ae507be structs needs to be PACKED 2020-11-09 15:24:19 +01:00
iceman1001 f894560325 hf mfdes fixes 2020-11-08 18:59:36 +01:00
Philippe Teuwen f63cf02178 make style 2020-11-07 01:32:43 +01:00
iceman1001 427e7c02e8 hf mfdes auth - textual 2020-11-06 23:52:11 +01:00
iceman1001 2cc5fb383c reorder command table 2020-11-05 12:50:51 +01:00
iceman1001 786accc487 fix coverity 286660 2020-11-02 17:59:30 +01:00
iceman1001 feddfe7f43 fix coverity 303441, 303442, 303486, 286660 2020-11-02 17:55:48 +01:00
iceman1001 e91c46616a fix, coverity 303794 2020-11-02 17:27:39 +01:00
Philippe Teuwen 777cb5a8ce make style 2020-11-02 01:46:47 +01:00
Philippe Teuwen a359e4fac4 Make use of aid_desfire info 2020-11-02 01:38:07 +01:00
NZSmartie c9a10631de
Gallagher key checking is now supported on MIFARE Desfire
Both `hf mfdes auth` and `hf mfdes chk` now support Key Diversification for
AN10922 and as special treat, Gallagher issued cards.

For `hf mfdes auth`:
```
    -d, --kdf <kdf>                Key Derivation Function (KDF) (0=None, 1=AN10922, 2=Gallagher)
    -i, --kdfi <kdfi>              KDF input (HEX 1-31 bytes)
```

And for `hf mfdes chk`:
```
    -f, --kdf <kdf>                Key Derivation Function (KDF) (0=None, 1=AN10922, Gallagher)
    -i, --kdfi <kdfi>              KDF input (HEX 1-31 bytes)
```

Examples:
- `hf mfdes auth -a 2081f4 -m 3 -t 4 -d 2 -n 2 -k 00112233445566778899aabbccddeeff`
  Will diversify the key for key `2` on AID `2081F4` for Gallagher issued cards

- `hf mfdes chk -f 1 -i 00112233 -d mfdes_default_keys`
  Will read in all the default keys from the dictionary, and diversify them
  using AN10922 with the input data `00112233`

- `hf mfdes chk -f 2 -d mfdes_default_keys`
  Will read in all the default keys from the dictionary, and diversify them
  using AN10922 but with input data generated from the card's UID, AID and
  key number.
2020-11-02 01:41:48 +13:00
NZSmartie 634c69398d
Split out mfdes_get_info from CmdHF14ADesInfo
Change needed so that UID can be read for later
2020-11-02 01:09:48 +13:00
NZSmartie 5a3502920c
Improve hf mfdes chk key checking and fix specifying single AID 2020-11-01 13:40:46 +13:00
NZSmartie b788054aca
Add initial suport for MIFARE Key Diversification
This adds two new options to `hf mfdes auth`

```
    -d, --kdf <kdf>                Key Derivation Function (KDF) (0=None, 1=AN10922)
    -i, --kdfi <kdfi>              KDF input (HEX 1-31 bytes)
```

By specifying `-d 1` and some kdf data `-i 00112233`, the key will be
diversified using AN10922.
2020-10-31 21:17:35 +13:00
Philippe Teuwen fdd11c3fb2 Fix MAD decoding for DESFire 2020-10-27 20:46:51 +01:00
Philippe Teuwen 66d5181a82 dfev3 pk 2020-10-27 10:30:19 +01:00
iceman1001 470a0a5978 actually fix the list options 2020-10-09 20:46:48 +02:00
iceman1001 64a44d1e85 adapt list command to allow for options 2020-10-09 20:19:36 +02:00
Philippe Teuwen c3c59e35cb make style 2020-09-30 14:27:19 +02:00
mwalker33 9560773e8f cliparser - round 3
updated cmdhfmfdes.c,  cmdhfmfp.c, cmdhfhfu.c, cmdlfindala.c and cmdlfmotorola.c
2020-09-30 19:38:40 +10:00
Ave d9ccd9ee24
hfmfdes: Fix a typo 2020-09-27 19:42:26 +03:00
Ave 9c5c00d620
Allow writes up to 256 bytes with mfdes writedata
And change help text to say 256 instead of 0xFFFF.

Closes #977
2020-09-27 19:40:13 +03:00
iceman1001 42eb98cdda rename 2020-09-24 23:20:15 +02:00
iceman1001 65478867d1 add check for NTAG413 2020-09-24 23:10:46 +02:00
Philippe Teuwen 8c4076281e Fix PK secp224r1 display 2020-09-24 13:58:45 +02:00
Philippe Teuwen ea8bfacb57 textual 2020-09-24 01:00:34 +02:00
iceman1001 2514ec740c uid 7 or 4 for desfire 2020-09-10 00:33:46 +02:00
iceman1001 5d357a6039 style 2020-09-07 10:39:15 +02:00
iceman1001 d09ed2eec0 no printf 2020-08-29 14:57:05 +02:00
Philippe Teuwen 4ed57c7c4d make style 2020-08-13 12:25:04 +02:00