Commit graph

258 commits

Author SHA1 Message Date
Philippe Teuwen ca43afa19b begin of dynamic capabilities handling in client 2019-05-01 20:48:15 +02:00
Philippe Teuwen 56f92348ea style 2019-04-29 22:41:28 +02:00
iceman1001 b08b1c2cd9 chg: 'hf mfu info' - ndef parsing was a bit wrong 2019-04-29 18:58:27 +02:00
iceman1001 9e34a8e56d chg: 'hf mfu info' - ndef has 4 byte blocks on UL/NTAG 2019-04-29 17:34:24 +02:00
Philippe Teuwen f1deb865db Merge branch 'master' into experimental_varlen
* master:
  ltrim cmd before display
  hf mf eload: fix absence of filename
  detect wrong numOfBlocks / numOfSectors arguments
  safeFile*: accept when suffix is already provided
  loadFile*: accept when suffix is already provided
  textual,  to reflect which repo.
  LoadEML: don't complain on the last \n
2019-04-28 22:53:12 +02:00
Philippe Teuwen 1dbcb712c3 safeFile*: accept when suffix is already provided 2019-04-28 20:42:57 +02:00
Philippe Teuwen eababdd3ef Merge branch 'master' into experimental_varlen
* master:
  chg: 'hf mf sim' - textual
  fix:  warning on mingw64.   This offset is calculated, casting it to u32 should be fine.
  fix: https://github.com/RfidResearchGroup/proxmark3/issues/174 remove all offending code,  return 1.   Will only impact the speed of hardnested execution.
  fix again OSX
  fix https://github.com/RfidResearchGroup/proxmark3/issues/173
  used predefined constants, common types moved to common header files
  backward compatibility, on load converter for old mfu dump format
  loops for counters output
  UL/NTAG new dump file format. Added counters support, simulation
2019-04-25 20:05:04 +02:00
Eloff a8c1fa7a3b backward compatibility, on load converter for old mfu dump format 2019-04-23 17:07:20 +03:00
Eloff 4161779083 loops for counters output 2019-04-22 23:20:35 +03:00
Eloff db3103b531 UL/NTAG new dump file format. Added counters support, simulation 2019-04-21 03:18:00 +03:00
Philippe Teuwen 238fc10c9a style 2019-04-20 01:08:07 +02:00
Philippe Teuwen c4766b2649 Semi-Automated SendCommand -> SendCommandOLD 2019-04-19 23:01:13 +02:00
Philippe Teuwen 1b6a45ac17 propagate CmdsParse return value 2019-04-19 00:47:51 +02:00
Philippe Teuwen 482db05741 Rename few stuff for consistency 2019-04-18 12:49:51 +02:00
Philippe Teuwen 533667ea6d Better Reply structs 2019-04-17 23:44:48 +02:00
Philippe Teuwen be15ad7fec Viva la revolucion 2019-04-17 21:30:01 +02:00
Philippe Teuwen 5c55664fc5 use more static and fix [-Wmissing-prototypes] 2019-04-13 21:57:13 +02:00
Philippe Teuwen 05374fce07 Rework Cmd exposed API, use more static and fix [-Wmissing-prototypes] 2019-04-12 19:41:56 +02:00
Philippe Teuwen 919cfb5841 more [-Wmissing-field-initializers] 2019-04-10 15:01:19 +02:00
Philippe Teuwen 0ab6de64d4 structs: initializes explicitely all fields, so we can detect when we really forgot one [-Wmissing-field-initializers] 2019-04-10 13:59:00 +02:00
Philippe Teuwen 3d6d58aae5 internal help fcts -> static 2019-04-10 13:06:05 +02:00
Philippe Teuwen cc0454d5d2 tag unused Cmd [-Wunused-parameter] 2019-04-10 12:23:40 +02:00
osboxes.org 598d016477 style 2019-04-10 09:47:46 +02:00
iceman1001 854536b155 unshadow 2019-04-08 09:39:05 +02:00
iceman1001 0b455607a9 fsize can't be zero 2019-04-07 12:41:29 +02:00
Philippe Teuwen 41f36ca20b make style 2019-04-06 19:09:01 +02:00
iceman1001 647dcc596f style 2019-04-05 09:18:52 +02:00
iceman1001 0383d7f052 chg: 'hf mf restore' - add finish message
chg: 'hf mfu restore' - add finish message
chg: 'hf 15 restore' - add finish message,  close filehandle when failing.
2019-04-03 15:34:36 +02:00
Philippe Teuwen db4aa08b78 make style 2019-03-28 14:19:41 +01:00
iceman1001 4288e9db73 style 2019-03-18 22:04:53 +01:00
iceman1001 2a6be74fd1 fix: operations inside macro expansion 2019-03-18 16:57:41 +01:00
Philippe Teuwen 961d929f4d changing {} style to match majority of previous style 2019-03-10 11:20:22 +01:00
Philippe Teuwen da6cdf014b Keep string syntax in color macros 2019-03-10 00:56:00 +01:00
Philippe Teuwen 0373696662 make style 2019-03-10 00:00:59 +01:00
Philippe Teuwen 0d9223a547 client: fix mix of spaces & tabs 2019-03-09 23:35:06 +01:00
Philippe Teuwen 60f292b18e remove spurious spaces & tabs at end of lines 2019-03-09 08:59:13 +01:00
iceman1001 9f10ff6e17 sugar 2019-02-24 10:26:55 +01:00
iceman1001 6d63b3fbed fix: mem leaks. 2019-02-21 16:17:49 +01:00
iceman1001 5ec82a0dc4 chg: adjustments 2019-02-18 16:27:56 +01:00
iceman1001 0997c55800 chg: colors 2019-02-18 16:07:39 +01:00
iceman1001 e6c68645e3 chg: colors 2019-02-18 13:28:22 +01:00
iceman1001 1ffddb2578 CHG: 'hf mfu dump' - simplify bin saving and added JSON dump format 2018-12-13 23:34:30 +01:00
Chris 25292eab2e fix: more warnings. 2018-11-14 15:13:17 +01:00
merlokk 0ef9b609dc mfu 2018-11-14 11:33:59 +02:00
merlokk b9974e1224 mfu 2018-11-14 11:24:21 +02:00
iceman1001 a2c7158f78 fixes from #616 2018-06-03 23:32:02 +02:00
iceman1001 d815ebdd4e fix: 'hf mfu dump' - partial dump detection 2018-05-03 23:01:30 +02:00
iceman1001 32a1bb4c01 fix: 'hf mfu dump' - increased timeout in order to read ntag216 tags 2018-05-03 21:54:53 +02:00
iceman1001 939b727c42 chg: converting malloc calls -> calloc which zeros out the allocated memory 2018-05-03 19:42:16 +02:00
iceman1001 6f7d0dffdc chg: unified download 2018-05-02 19:52:31 +02:00
iceman1001 a8dbbc1609 chg: forgot one 2018-05-02 08:13:23 +02:00
iceman1001 0aa6568bf9 fix: 'hf mfu' increase array 2018-04-04 12:28:30 +02:00
iceman1001 4b2a746ef5 ADD: 'hf mfu' detection of Mifare Ultralight NANO tags.
Interesting tag with two new commands.  LOCK_SIG  / WRITE_SIG.   Need to add support for it.
https://www.nxp.com/docs/en/data-sheet/MF0UN_H_00.pdf
2018-04-03 09:57:20 +02:00
iceman1001 3d92a616b7 fix: to_lower -> tolower 2018-03-19 19:24:52 +01:00
iceman1001 c814615e1b chg: helptext now shows correct sample key. (thanks @Dmanufacturer for pointing it out) 2018-03-19 19:19:57 +01:00
iceman1001 0abb85a411 chg: 'hf mfu dump' - renamed filename parameter from 'n' to 'f', since 'f' is used on other command (iClass)
chg: generic to_lower can remove some cases
2018-03-19 18:16:33 +01:00
iceman1001 0656edbb85 chg: 'hf mfu dump' message 2018-03-17 14:34:55 +01:00
iceman1001 b0eaa730c0 FIX: 'hf mfu dump' - partial reads leads to overwritten data on wrong blocks. 2018-03-16 16:31:10 +01:00
iceman1001 0eca7e3977 chg: #define rename 2018-03-16 08:58:07 +01:00
iceman1001 7a71df3aec syntax sugar 2018-03-15 22:35:11 +01:00
iceman1001 24482211ad chg: the dot progress is not logged anymore. Force fflush afterwards. 2018-03-05 20:07:29 +01:00
Brian Pow 4306f85343 tweak messages 2018-02-21 20:43:54 +08:00
Brian Pow 5b0233854d use PrintAndLogEx() instead of PrintAndLog() 2018-02-21 20:43:49 +08:00
Brian Pow ec0fa961a1 use PrintAndLogEx() instead of PrintAndLog() 2018-02-21 20:43:49 +08:00
Brian Pow b1d414c680 CHG: replace 'samples:' with 'Examples:', unify some usage text 2018-02-09 22:56:16 +08:00
iceman1001 681f2cc83d fix: bad compare. 2018-01-25 18:10:34 +01:00
iceman1001 07bf77e155 fix: 'hf mfu restore' - printed too many bytes. 8 -> 4 2017-12-03 15:58:37 +01:00
iceman1001 3b4b7812bf fix: removed a warning, 2017-12-02 19:01:43 +01:00
iceman1001 6e144e0121 chg: removed line 2017-11-29 07:19:51 +01:00
iceman1001 2a120ec2e0 fix: no copy the crc 2017-11-29 07:18:43 +01:00
iceman1001 53452ab857 fix: 'hf mfu info' - rfu should n't print pack.
fix: 'hf mfu info' - wrong pointer to cli authenticationkey
2017-11-28 21:23:58 +01:00
iceman1001 bed2ff2dba fix: wrong place.. key got overwritten.. 2017-11-28 20:36:29 +01:00
iceman1001 bc9b2af87e ADD: NTAG213F,NTAG216F specific information in configuration blocks.
ADD: insert pwd/pack if specified from cli.
2017-11-28 20:03:46 +01:00
iceman1001 5f58dcfa52 fix: 'hf mfu dump' - wrong. 2017-11-28 09:25:36 +01:00
iceman1001 6fa8740abd fix: 'hf mfu info' - select before testing a new pwdgen.
fix: 'hf mfu info' - break after found pwd
2017-11-27 20:04:54 +01:00
iceman1001 b99d759231 fix: compare not assign 2017-11-27 09:23:21 +01:00
iceman1001 f46546c5a9 ADD: 'hf mfu info' - tag identification should now identify NTAG213_F , NTAG216_F (thanks for info @jackfagner) 2017-11-27 09:21:55 +01:00
iceman1001 428e54bb6b CHG: 'hf mfu' gettype identification, now deals with NTAG213, GetVersion = subtype 04, 2017-11-26 19:16:12 +01:00
iceman1001 1ebf4afd73 CHG: 'hf mfu info' - now also tests for pwdgen algo D. 2017-11-26 16:52:20 +01:00
iceman1001 0815f19389 ADD: new pwdgen algo, (thanks @jackfagner) who did a great job figuring it out. Read his blog.
ref.   https://github.com/jackfagner/NfcKey/blob/master/NfcKeyC.c
2017-11-25 08:48:36 +01:00
iceman1001 2f3dbbcaa3 rename: ul_switch_off_field -> DropField (inside cmdhf14a.c)
chg:  Fix memory bounds error (@wsmoses)
 c3511781a1
2017-11-11 23:23:01 +01:00
iceman1001 9b4e52b89e CHG: dropfield 2017-11-10 20:49:56 +01:00
iceman1001 a4b4a1a9a2 FIX: iso-14443a RATS optional (piwi) 2017-10-01 22:06:06 +02:00
iceman1001 d2f19521a7 fix: 'hf mfu restore r' it now uses the newly written pwd for all further authentications needed.
- it also tries to save the special blocks, and configurationblocks in a certain order.
2017-07-17 14:27:11 +02:00
iceman1001 da32472099 chg: 'hf mfu restore' added the parameter 'r', to read the password from the dump file and write to a magic ntag 21* , to be used together with the parameter 'e' 2017-07-15 14:03:11 +02:00
iceman1001 1b6176995f chg: 'hf mfu restore' swapped some parts so to write special areas first and configblocks last. 2017-07-14 21:24:36 +02:00
iceman1001 c5e04ba927 fixes: removed bad references.
chg: 'hf mfu restore e' added the special block writes options
2017-07-14 08:47:23 +02:00
iceman1001 b99fa57e42 fix: wrong variable 2017-07-13 23:37:09 +02:00
iceman1001 7cf0bf19e5 FIX: 'mfu authentication' bug where the pack-length was wrong
ADD: 'hf mfu restore'  - added a restore from file command, see helptext for instructions
CHG: some help-text updates and refactored to functions
CHG: 'hf mfu gen'  - added the possibility to read uid from card as input
CHG: 'hf mfu dump' - refactored out the dump-printing
2017-07-13 13:10:46 +02:00
iceman1001 17a8e69e90 ADD: 'hf mfu info' type detection now support NTAG_I2C_1K_PLUS, NTAG_I2C_2K_PLUS
ADD: 'hf mfu info'  ul-ev1 pwd tests are now correct
ADD: 'ul ev1 authentication' now deals with magic tags and NACK messages correct.
ADD: 'hf mfu pwdgen'  added the option 'r' to read uid from tag instead.
2017-07-11 17:52:01 +02:00
iceman1001 ab2167c47b FIX: 'hf mfu dump' - the ascii printing would print control-chars, which could hang client. Unprintable chars is replaces with a DOT 2017-02-14 15:52:28 +01:00
iceman1001 cf5a79de33 ADD: 'hf 14a read' - correct identify Aztek tags, instead of claiming it to be "not mfu". 2017-02-04 12:32:14 +01:00
iceman1001 2dcf60f3df CHG: "hf mf hardnested" - less printing
CHG: some filehandles = NULL.
2016-10-21 16:06:53 +02:00
iceman1001 0e32bf46e7 CHG: added the ascii output for the pwd. 2016-04-14 11:32:43 +02:00
iceman1001 683180cb60 ADD: added a simple test of known pwd algos based on uid. 2016-02-24 08:31:46 +01:00
iceman1001 54d893143c FIX: Coverity, out-of-bounds read ... 2016-01-13 14:51:02 +01:00
iceman1001 28415b5d90 FIX: Coverity, unchecked return value, CID #121292,..
basicallty the flush queue commmand is replaced with clearCommandBuffer();.
2016-01-12 22:30:22 +01:00
iceman1001 dd79e03a1a ADD: a new pwdgen algo Nicknamed C, (Huge props to @Bettse for everything) also added to the "hf mfu info" command. However, that will not work given the system's lockbits.. :( Maybe I'll add a function to test all imp pwdgens given a UID without making a authentication call to tag.
ADD:   BSWAP_32 macro, for changing endianness.
2016-01-09 17:17:36 +01:00
iceman1001 e869d59871 ADD: @marshmellow42 's changes to "hf mfu dump" 2015-12-21 19:48:33 +01:00
iceman1001 9332b857ff ADD: @marshmellow42 's fixes for Q5, t55xx, fskclock,
ADD:  got tired of always writing wrong "hf 14a list",  so I hooked it back up to call the "hf list" with argument. Things becomes smoother that way.
2015-12-16 11:01:46 +01:00