Commit graph

270 commits

Author SHA1 Message Date
iceman1001 a8569849d6 part of monstermerge.. 2017-07-27 20:58:59 +02:00
iceman1001 e8015142cd fix: TRUE/FALSE -> bools
fix: 'iclass'  filepath 255, to use FILE_PATH_SIZE
fix: unified params test
2017-07-14 20:54:11 +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 310d0da9a4 fixes.. to bool 2017-07-11 18:31:10 +02:00
iceman1001 1f9534e2cc CHG: broke out some help texts and improved them.
CHG: 'hf mf csave' now save mini,1k,2k,4k and to both a bin and eml file.
2017-07-11 17:45:23 +02:00
iceman1001 3ca3d401c0 FIX: some adjustments to prng detection 2017-07-04 20:11:25 +02:00
Iceman 08cc2c36d8 fix: 'hf mf chk'
Dictionary files will load wrong if they exceed 256lines.
2017-04-26 19:52:03 +02:00
angelsl ece631fd06 Add Mifare Classic EV1 set load modulation command 2017-03-09 21:37:16 +08:00
iceman1001 be67483e63 syntax sugar 2017-03-09 11:19:30 +01:00
iceman1001 57778a4630 CHG: renamed struct sector -> sector_t
CHG: defines on armside
CHG: #define WIN32 ->  _WIN32
CHG: started to enhance "hf mf chkkeys"
REM: removed some duplicates etc in default keys.
2017-03-06 19:11:08 +01:00
iceman1001 a9eeb57698 CHG: Added PR #220 from PM3 Master. ref: https://github.com/Proxmark/proxmark3/pull/220 2017-03-01 20:14:46 +01:00
iceman1001 5215a87442 CHG: @Marshmellow42 's fixes. ref: e88096ba25 2017-02-24 01:14:47 +01:00
iceman1001 9c624f67b3 chg: @piwi's code cleanup and some more.
ref: 43534cbad2
2017-02-23 00:03:10 +01:00
iceman1001 84bdbc1917 FIX: 'hf 14a sim x' - adjusted and shows messages when verbose.
FIX: 'hf mf sim x i' - same as above.

In general we only use Moebius attack for "sim x",  that means a clean up on device side code. simpler to understand. It still tries to gather 8 different collections of nonces combo. When one is complete, it get sent to client which runs moebius direct.
2017-01-29 23:09:23 +01:00
iceman1001 2ce218042d CHG: 'hf 14a sim e' - it now has a parameter for setfoundkeys to emulator memory.
CHG: textual changes.
2017-01-29 13:21:17 +01:00
iceman1001 7e735c1398 FIX: 'hf 14a sim x' - this fixes the error with using moebius attack and sim. Updating the nonce variable doesn't change the premodulated response. And it should update everytime it gets a command. One concering issue is that this takes time. Successfully works with two PM3. One acting reader, another sim. 2017-01-29 11:29:15 +01:00
iceman1001 e108a48ac4 ADD: added the 'hf mf hardnested' to be called within LUA scripts.
ADD: 'script run hard' - a first try for a lua script to run the hardnested attack on a complete tag.
2016-11-21 16:08:12 +01:00
iceman1001 2618e313bf CHG: textual change 2016-11-16 17:45:12 +01:00
iceman1001 60c33f7aa8 CHG: minor textual change to fit the minimum two calls nature for the zero parity attack 2016-10-29 21:45:36 +02:00
iceman1001 19693bdc06 FIX: 'hf mf mifare' - special zero parity attack vector now works. Thanks to the dude who figured this vector out: @douniwan5788 (sorry for comments, I was clearly wrong.) @piwi - for proving me wrong.
this version uses int64_t  (signed)  to signify end-of-lists (-1). It also needs its own compare function for the qsort.  I didn't merge this into existing code which uses uint64_t. (too lazy)
2016-10-29 21:41:02 +02:00
iceman1001 ba39db376c CHG: just some parameter / variable name changes. Nuttin' special. 2016-10-28 16:37:01 +02:00
Michael Farrell 32beef538e hf {14a,mf} sim: v is for verbose 2016-10-27 23:37:00 +11:00
Michael Farrell dfdbfa0702 hf mf sim: Be less verbose by default, add option "m" to turn maths back on (Issue #45) 2016-10-27 23:37:00 +11:00
Michael Farrell b6e05350b2 hf mf sim: Multiple fixes (iceman1001/proxmark3 #45)
- Fix `hf mf sim` to use nonce_t structures, so key recovery works
- Increases verbosity on the key recovery functionality
- Fix use-after-free for k_sector
- Add help info on `e` option to `hf mf sim`
2016-10-22 21:53:53 +11:00
iceman1001 2dcf60f3df CHG: "hf mf hardnested" - less printing
CHG: some filehandles = NULL.
2016-10-21 16:06:53 +02:00
iceman1001 f885043422 FIX: "hf 14a read" / "hf mf *" / "hf mfdes info" and failure when calling these commands serveral times in row.
For long transactions the sspclock compare with >1 instead of >=1 ..   Now the timer resets properly.
CHG: use some #define constants for iso-commands.
2016-09-23 21:28:07 +02:00
iceman1001 5b4664e79f CHG: Adding clarity to the command helptext. 2016-09-01 20:36:42 +02:00
iceman1001 ba1324a5fe some text changes. 2016-08-24 14:58:50 +02:00
iceman1001 760157f50b CHG: added a verification to see if the found candidate key was able to validate against tag. If not ok, start darkside attack again. 2016-08-24 14:10:30 +02:00
iceman1001 6067df30c5 FIX: at least now the special zero parity attack, repeats and doesn't crash. However it doesn't find the key either :( 2016-08-10 10:55:29 +02:00
iceman1001 59e933fc3f started fixing the paritiy == 0 special attack against chinese clones with bad prng, which hasnt been working for ages. 2016-08-09 23:11:07 +02:00
iceman1001 d9ed4e1914 ADD: J-Run's 2nd phase tool mf_key_brute ref: https://github.com/J-Run/mf_key_brute Estimated time to search keyspace is ~18min.
J_Run's 2nd phase of multiple sector nested authentication key recovery
You have a known 4 last bytes of a key recovered with mf_nonce_brute tool.
First 2 bytes of key will be bruteforced

Usage:  hf mf keybrute [h] <block number> <A|B> <key>
options:
      h               this help
      <block number>  target block number
      <A|B>           target key type
      <key>           candidate key from mf_nonce_brute tool
samples:
           hf mf keybrute 1 A 000011223344
2016-08-08 17:49:30 +02:00
Alexis Green 170e7c9c51 FIX: erroneous semicolon 2016-08-07 20:07:25 -07:00
iceman1001 df007486f5 ADD: @donwan581 select keytype for the darkside attack. 2016-08-04 21:51:26 +02:00
iceman1001 2fdc489bb4 CHG: printing of progress dots is better now. 2016-05-19 12:47:23 +02:00
iceman1001 ea1ee62e55 CHG: better helptext 2016-04-29 22:24:08 +02:00
iceman1001 222bdb1cb3 Syntax suger 2016-04-24 21:43:38 +02:00
iceman1001 cd777a0545 FIX: Some Coverity Scan warnings. fread, not initialised etc etc 2016-04-23 18:23:46 +02:00
iceman1001 be6e909c5b FIX: time printing, like difftime in MINGW enviroments needs to use 32b time. 2016-04-23 13:02:20 +02:00
iceman1001 9ea10847ea CHG: timeing in chk keys, 2016-04-23 12:26:29 +02:00
iceman1001 fa0e0b109f CHG: moved out some usage_methods for help texts.
CHG: added some time in the darkside, nested, hardnested, chk commands.
2016-04-23 12:18:34 +02:00
iceman1001 5dc8b8fe27 CHG: unified some text messaged. 2016-04-23 11:43:02 +02:00
iceman1001 d948e0d140 CHG: 'hf mf chk' now correctly tests to read key B, when we specify target keytype B or ?.
CHG: 'hf mf chk'  now correctly init all sector keys to 0xFFFFFFFFFFFF,  so it looks unified.
2016-04-23 11:32:37 +02:00
iceman1001 6c84c90017 FIX: this fixes the "hf mf sniff l d f" command, which has been broken for a while. The cuid is correct used for decrypting.
FIX: The flushing of logentries.
ADD: "hf mf sniff" - added the sniffing of UID's with a uidlen of 10.

Whats left? The key is not always found even if we use the "mfkey64" approach.

ADD: added the parity_zero attack in "hf mf mifare".  Still not working since piwi's changes to the iso14443a.c,  maybe needs a param to tell it to collect nonces for this special attack.
CHG: extracted some help-texts into usage_* methods. Changed some text as well

FIX:  "hf mf sim" command now uses both  mfkey32 and mfkey32_moebius version to find the key in attack mode.
CHG:  "hf mf sim" also now defaults to emul_memory to read a 4 byte UID.
2016-04-18 13:18:02 +02:00
iceman1001 0194ce8fc8 ADD: simulating can now handle triplesized UID (10b)
CHG: moved some mifare #DEFINES into protocols.h  (ACK,NACK..)
2016-04-14 11:09:17 +02:00
iceman1001 2daa0d0b1e CHG: doesnt flush the printf() calls 2016-04-10 13:34:27 +02:00
iceman1001 c3559d162a textual changes 2016-03-23 14:04:10 +01:00
iceman1001 b03006794f CHG: removing some time-debug statements.
CHG:  increased the time-out message 2sec, in proxmark,  to make "hf mf chk" work better.
CHG:  still trying to solve the "hf mf mifare" WDT_HIT bug.

With these changes,  the "hf mf chk" / "Hf mf nested" looks similar and should be a bit faster.
2016-02-19 22:34:39 +01:00
iceman1001 b882b54314 FIX: introduced a bug in a loop by uint8_t inside crapto1.c
CHG: textual helptext change in "hf mf nested"
CHG: loop inside "nested". Still not fast enough. I wonder if qsort can be exchanged for radixsort or bucket sort?
2016-02-16 23:46:34 +01:00
iceman e7902ca0a5 chg: removed testmessage 2016-02-15 02:45:43 +01:00
iceman 480e2f2394 Merge branch 'master' of https://github.com/iceman1001/proxmark3
Conflicts:
	client/cmdhfmf.c
	client/cmdmain.c
2016-02-10 13:29:23 +01:00
iceman 847f7404ff CHG: added some timing messages, 2016-02-10 13:20:23 +01:00
iceman1001 a9e4e78f83 CHG: syntax suger 2016-02-10 13:12:01 +01:00
iceman1001 d294f5825d CHG: Syntax suger
Experiment:  unfolded a loop.
Experiment: speeding up "Hf mf nested"
CHG: removed some default keys from "hf mf nested". It wasn't being used anyway.
CHG: changed the way "hf mf nested" reports back keys
CHG: "hf mf nested"  and "hf mf chk"   now prints the key-table.
CHG: changed the output list for "hf mf chk"
2016-01-25 20:28:34 +01:00
iceman1001 f66114426b CHG: removed a debug statement 2016-01-21 13:01:07 +01:00
iceman1001 810f53792e ADD: added the possibility to choose which block num to attack with "hf mf mifare" Before it only worked on block 0. 2016-01-20 22:26:01 +01:00
iceman1001 0920f54c66 CHG: Remake the "hf mf chkkeys" It now prints the found keys like "hf mf nested" does. It also tries to read key B if Key A was found. It also continues to the next key to find, when there is one match. Earlier all keys in .dic file, was tested even if it was found. 2016-01-20 19:51:30 +01:00
iceman1001 495d7f1326 FIX: Coverity scan, forgot one fread ...
CHG: Syntax suger
2016-01-19 22:25:34 +01:00
iceman1001 b112787d4f ADD: Some instructions for configure CoverityScan using alternative compiler like the ARM-NONE-EABI-GCC
FIX: stupid clock() == -1 on systems who doesn't have it..
2016-01-19 21:48:29 +01:00
iceman1001 841d7af0dc FIX: Coverity Scan warnings on not using the fread return value. 2016-01-19 19:52:01 +01:00
iceman1001 a0f33b6682 CHG: started to clean up the crapto1 imp in client/nonce2key/ folder. 2016-01-19 17:22:18 +01:00
iceman1001 0697080e26 FIX: CoverityScan complains on getchar(), not reading the returning value 2016-01-19 16:58:07 +01:00
iceman1001 4750877f2d FIX: Coverity fix with resource leakage
ADD: Implemented a addon to "hf mf nested"  if there is KEY_A 's found but not the same KEY_B,  try just read it from tag.
Makes the command a bit slower when it does these reads.   Plus some annoying debug statements,

CHG: changed the output for "hf mf nested"  to write Key A or B instead of 0 & 1..
2016-01-16 23:02:04 +01:00
iceman1001 621601ecef ADD: some clocking for 'hf mf mifare', 'hf mf nested', 'hf mf chk' 2016-01-15 12:45:15 +01:00
iceman1001 4b8ee00f0d FIX: forgot to change a modified call from @pwpivi 's last update. 2016-01-13 12:49:21 +01:00
iceman1001 0d5ee8e245 ADD: @pwpiwi 's latest changes to 'hf mf hardnested' 2016-01-13 09:31:13 +01:00
iceman1001 95d96ea38a FIX: Coverity, Unintended sign extension, data[7] would have become int, then uint64_t. Should work better now with adding typecasting. 2016-01-12 23:40:57 +01:00
iceman1001 3906036e11 FIX: Coverity, Resource leak, CID #121361, filehandle f needs to be free 2016-01-12 23:38:47 +01:00
iceman1001 e683ecb6a5 FIX: Coverity, Resource leak, CID# 121360, keyBlock needs to be free 2016-01-12 23:37:33 +01:00
iceman1001 60daed79db FIX: Coverity, out-of-bounds write, CID#121340, CID#121341, CID#121342, CID#121343, wrong size in check, sprintf always adds a null terminator, so if filepath would have been 996 chars long, this might had happend... but no more. 2016-01-12 23:35:06 +01:00
iceman1001 f1db8c2207 CHG: Syntax suger 2016-01-12 23:29:05 +01:00
iceman1001 e72d1fbba2 FIX: Coverity, CID#121314, Explicit null dereferenced, in really odd occasions buf would be NULL, and sending NULL to memcpy dereferences it. Not sure about this fix. 2016-01-12 23:27:42 +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 c46ea881a4 FIX: coverty scan, resourceleak in "hf mf sniff", added call to 'free' befor return.
FIX: coverty scan, overflow in "hf 14a raw",  added an extra len check against USB_CMD_DATA_SIZE
2016-01-08 14:30:56 +01:00
iceman1001 2b1f4228c2 ADD: @marshmellow42 's changes to "hf mfu *" ,
ADD: @marshmellow42 's changes to "hf mf sim",
ADD: @pwpiwi 's parity files was missing.
2015-12-15 09:34:55 +01:00
iceman1001 f8ada309e9 ADD: @pwpiwi 's latest code from his 'hardnested' branch. 2015-12-15 08:51:29 +01:00
iceman1001 d08faa4e02 ADD: Added the possibility to exit the bruteforce mode (either rangesearch or file) with the keyboard.
FIX:  if not found, the range search printed wrong number.
2015-12-01 22:47:03 +01:00
iceman1001 21865cda09 ADD: added the possibility to load a default pwd file to be used with the "lf t55xx bruteforce" command.
new option:
      lf t55xx brutefore i default_pwd.dic    -  will load default pwds from file and test against tag.
2015-12-01 13:07:01 +01:00
iceman1001 c188b1b9b2 ADD: @go_tus simple bruteforce for t55xx, refactored a bit.
ADD: @pwpiwi 's implementation of Hardnested
2015-11-27 16:24:00 +01:00
iceman1001 0956e0dba5 FIX: an error that I introduced to the csetblock command with wrong length of crc calcs.
CHG:  variable name in csetblock change.  just trying to be consistant.
ADD:  code clean up in hf 14a,  added some help text methods.
2015-11-10 11:45:45 +01:00
iceman1001 c2731f37be CHG: a major remake of the "hf mf c*" commands. Ie chinese magic tags. Tried to make them consistent in parameter calls and simplified. And fixed the annoying gen1 tags that answers with a ACK/NACK on HALT commands.. 2015-11-09 21:46:15 +01:00
iceman1001 2285d9dd94 FIX: I did a clean up of the "LF PCF7931" code. The write command is not quite done.
FIX: Added some more "clearCommandBuffer" calls before sending..
2015-10-12 21:30:54 +02:00
iceman1001 3bc7b13d23 ADD: @marshmellow42's decrypt crypto-1 method,
ADD:  @piwi's latest commit to PM3 Master, aiming at the WDR in "hf mf mifare".
2015-10-11 09:07:29 +02:00
iceman1001 e98572a1e2 I just merged @marshmellow's branch "iclass" and that was a lot of new functionality. *great work*
Things like the ICLASS, tryDecryptWord,

--
My other stuff like default keys, some new Mifare EV1 commands 0x40, 0x43 for the logging annotation,  start of the T55x7 configblock helper functionality (ripped from Adam Lauries RFIdler code)
Changes to the PCF7931 functions written,  which has a lousy input check..
2015-10-07 23:00:46 +02:00
iceman1001 0de8e3874d A lot of changes...
.. ntag simulation stuff from @marshmellows branch "ntag/sim"
.. hf mf mifare fixes from @pwpivi.
.. hw status command
.. speedtest function from @pwpivi
.. Viking Functionalities,   (not a proper DEMOD, but a start)
.. GetCountUS  better precision from @pwpivi
.. bin2hex,  hex2bin  from @holiman

...
starting with getting the T55x7 CONFIGURATION_BLOCK for different clone situations. Ripped from Adam Lauries RFidler,   nothing working or finished..
...
Started working with the T55x7 read command with password actually performs a write block...  See Issue #136  https://github.com/Proxmark/proxmark3/issues/136    Not solved yet.

...
Started add SHA256..   not working yet..
2015-10-04 18:01:33 +02:00
iceman1001 b10a759fef @PM3 master merges, Piwi fix for mfnested
@Marshmellow42 's fix for FDB
2015-07-12 22:58:16 +02:00
iceman1001 c830303d7e FIX: @pwpiwi 's fixes for darkside / nested attack about the NACK/PRNG bugs. 2015-06-25 12:41:39 +02:00
iceman1001 4abb052f38 CHG: removed an extra fclose call 2015-06-02 12:20:48 +02:00
iceman1001 95aeb706d7 CHG: @marshmellow42 changes on deviceside.
ADD: increase debuglevel for printing a statment in ul_ev1_auth
2015-05-27 23:23:46 +02:00
iceman1001 c3c241f389 CHG: moved a xor function into util.c
CHG: added some calls to clearCommandBuffer() in /hf mfu/hf 14a sim/hf mf sim/ commands.
CHG: minor adjustments to relative pathing.
2015-05-26 11:04:57 +02:00
iceman1001 7c60a801d6 FIX: one too many parenthesis 2015-05-25 13:16:10 +02:00
iceman1001 c068ebb78f Merge branch 'master' of https://github.com/Proxmark/proxmark3
Conflicts:
	armsrc/mifarecmd.c
	client/cmdhfmf.c
2015-05-25 13:13:06 +02:00
iceman1001 46cd801c5a FIX: dumptoemul.lua removed the extra linebreak in the end, making some load commands complain.
MOV: moved the try32/try64 attacks (mfkey32/mfkey64) into the nonce2key.c file
CHG: added @marshmellow42 changes to hf mfu dump layout.
ADD: an extra call to BigBuf_free in readcard..  just to make sure that it doesn't leak memory.
ADD: expermimental call to "try32" for "hf mf sim x".
2015-05-25 13:10:55 +02:00
Pierre LALET 292fe72535 Fix filenames for hf mf cload / csave 2015-05-24 22:43:08 +02:00
iceman1001 d23f3f2c9a FIX: ELOAD/ESAVE/CLOAD/CSAVE filename bufferoverflow, and filename generation if UID not readable.
Thanks @p-l-
ref: 0b14440dce
2015-05-24 21:50:15 +02:00
Pierre LALET 0b14440dce Fix filenames for hf mf esave / eload 2015-05-24 20:14:22 +02:00
iceman1001 bcf61bd34a Merge branch 'master' of https://github.com/Proxmark/proxmark3
Conflicts:
	README.txt
	armsrc/appmain.c
	armsrc/apps.h
	armsrc/des.c
	armsrc/iclass.c
	armsrc/mifarecmd.c
	armsrc/mifareutil.c
	armsrc/mifareutil.h
	client/cmddata.c
	client/cmdhf.c
	client/cmdhf14a.c
	client/cmdhficlass.c
	client/cmdhfmfu.c
	client/cmdhfmfu.h
	client/cmdscript.c
	client/lualibs/commands.lua
	client/lualibs/html_dumplib.lua
	client/scripting.c
	client/util.c
	common/protocols.h
	include/usb_cmd.h
2015-05-23 08:16:40 +02:00
marshmellow42 e6432f0579 @iceman1001 s coverity scan fixes 2015-05-13 11:14:17 -04:00
iceman1001 664bb5ae72 BUGS: more Coverity scan fixes. 2015-05-13 14:08:59 +02:00
iceman1001 2696349f16 BUGS: Coverty Scan, fixes some memory bugs 2015-05-13 13:23:53 +02:00
iceman1001 fab0b37968 CHG: removed linebreak in string. 2015-04-26 18:05:45 +02:00
marshmellow42 664f658650 nexwatch fix .h file + icemans mf csetblk w arg
forgot to include the new nexwatch command in the header...
added icemans hf mf csetblk w parameter fix
2015-04-08 15:08:05 -04:00
Martin Holst Swende 83602affe5 Fixed buffer initialization errors, as reported in http://www.proxmark.org/forum/viewtopic.php?pid=15337#p15337 2015-04-08 13:31:04 +02:00
marshmellow42 9f7bbd24c9 data autocorr additions 2015-03-13 12:23:26 -04:00
pwpiwi 16a95d76ac fix: (issue #73) hf mf cload didn't work. Add more annotations for Magic Cards operation. 2015-03-09 21:36:27 +01:00
Jesse Hallio 3bba7deac0 Add settable ATQA and SAK to hf mf csetuid command. 2015-02-10 04:31:53 +02:00
pwpiwi f71f4deb8f BigBuf and tracing rework: allow much longer traces in in hf commands
- provided a BigBuf_malloc() function to dynamically allocate parts of BigBuf
  e.g. for DMA-Buffers, Frame-Buffers, Emulator-Memory
- the whole rest of BigBuf is now available for traces (instead of a small fixed amount)
- send actual traceLen together with trace data
- changed client side to cope with varying traceLen
- changed small buffers to automatic variables instead of parts of BigBuf
2015-01-28 07:18:51 +01:00
iceman1001 e3c235654f Minor fixes to some help-texts. 2015-01-20 21:48:39 +01:00
iceman1001 5ee701292f Step 2 - Ultralight / Ultralight-C
With this the Pentura Labs / Midnitsnakes's original ultralight / ultralight-c implementation is enhanced and move to its own file. cmdhfmfu.c
2015-01-20 21:23:04 +01:00
Martin Holst Swende 31d1caa526 Reverted some minor things, altered other things to get it to compile cleanly 2015-01-08 17:51:52 +01:00
iceman1001 787b5bd8a4 CHG: minor code clean up in ArmSrc.
ADD: added some more default keys in Hf mf nested,  maybe it runs faster :)
2015-01-08 00:08:33 +01:00
iceman1001 b915fda392 FIX: a solution for the issue "hf mf esave - always saves 4K"
FIX: a solution for the issue "hf eload, esave, cload, save - filepath variable too short"
CHG: minor code clean up.
ADD: AES / CRC16 for lua. (and tnp3xx scripts.)
ADD: tnp3dump.lua  script to dump tnp3xx tags.
ADD: tnp3sim.lua script to let PM3 imitate an tnp3xx tag. Needs to be tested live
2015-01-07 22:00:29 +01:00
iceman1001 52ab55ab0d ADD: added a lot of ic ids to cmdhf15.c Thanks to Asper for the list.
ADD: added a manufacturer list in "hf 14a reader",  only viable when UID is double or triple size.  Thanks to Asper for the list.
ADD: detect chinese magic backdoor commands in "hf 14a reader"
CHG: minor code clean up.
2015-01-07 21:06:15 +01:00
iceman1001 3fe4ff4f03 CHG: generic code clean up. Removal of commented code.
CHG: USB_CMD_DATA_SIZE is now used as maxsize for transfer of data between client and pm3device
CHG: suggested a fix for the underscore problem in ioclass\fileutils.c
ADD:  tnp3xx support
ADD:  nxp tag idents.
ADD:  identifiction of chinese backdoor commands to hf 14a reader.
2015-01-05 15:51:27 +01:00
pwpiwi 6a1f2d82bb bugfixes iso14443a (hf 14a commands)
- buffers were too small to handle 256 byte frames
- parity bits were only handled for up to 32 byte frames
- trace format was inefficient
- removed parity calculation from decoders in iclass.c (parity not used on air anyway)
2014-12-16 07:41:07 +01:00
Martin Holst Swende ca4714cd23 More coverity fixes 2014-10-30 21:49:18 +01:00
Martin Holst Swende 97d582a692 More coverity findings 2014-10-27 22:33:37 +01:00
Martin Holst Swende 90e278d3da Fixed several issues found using a coverity-scan 2014-10-27 21:46:04 +01:00
pwpiwi c626c56ef5 hf mf dump bugfix: wrongly tried key A instead of key B for a specific Access Condition 2014-09-12 07:45:04 +02:00
pwpiwi 79db03ef63 hf mf dump error handling, revive hf mf chk d option, provide known keys dictionary file
- hf mf dump: abort on unrecoverable errors. Don't create file dumpdata.bin in this case.
- hf mf chk: re-enabled and fixed option d (dump keys to dumpkeys.bin).
  if there are unknown keys, write 0xffffffffffff instead to the file.
- provide a default key dictionary file for hf mf chk (default_keys.dic). Contents taken from
  mf_default_keys.lua
2014-09-11 20:58:34 +02:00
pwpiwi baeaf57950 fix/add support for 4K (and other non 1K) card sizes in hf mf commands
- hf mf rdsc (fix): didn't account for 16 block sectors, allowed max sector 63 instead of 39
- hf mf ecfill (add): added (optional) card size parameter and support for non 1K cards
- hf mf dump (add): added (optional) card size parameter and support for non 1K cards
- hf mf dump (fix): Access Condition 011 not handled correctly (tried to access with key A)
- hf mf restore (add): added (optional) card size parameter and support for non 1K cards
- hf mf nested (fix): didn't account for 16 block sectors, allowed max sector 63 instead of 39
- hf mf nested (fix): always dumped 16 keys to dumpkeys.bin instead of correct number
- hf mf chk (fix): always dumped 16 keys to dumpkeys.bin instead of correct number
- hf mf eget (fix): displayed three instead of one block
- hf mf eload (add): load 4K .eml files (but accepts 1K .eml files for backwards compatibility)
- hf mf esave (add): always save the whole emulator memory (4K) instead of 1K only
- hf mf ecfill (add): added (optional) card size parameter and support for non 1K cards
2014-09-10 19:04:50 +02:00
pwpiwi b03c0f2d86 bugfixes hf mf sim
- output of debug messages caused communication failures due to timing issues.
  hf mf dbg 4 now required to see these debug messages.
- changed help text for hf mf dbg
- fixed minor bugs in help texts for hf mf sim and hf mf ecset
- display "key A" or "key B" instead of "key=0" or "key=1 in hf mf sim
2014-07-30 21:23:02 +02:00
pwpiwi 991f13f27d minor bugfixes to hf mf sniff and hf 14a snoop
- tracing was not always enabled when starting hf mf sniff or hf 14a snoop
- ATQA was displayed in wrong byte order in hf mf sniff
- 4 Byte UIDs were displayed as 7 Byte UIDs (padded with 0x000000) in hf mf sniff
- same for logfile names.
- assignment (=) had been used instead of == in comparisons (shouldn't have been relevant though)
2014-07-15 08:39:56 +02:00
holiman f5a1a9ce47 Merge pull request #8 from pwpiwi/master
add .gitignore and merge svn r852
2014-03-25 21:49:05 +01:00
pwpiwi d714d3effc Improvements/Fixes to 14443 sniffing/snooping
- fixed a circular buffer rollover bug in iso14443a.c
- fixed 7 Byte UID handling in hf mf sniff
- fixed "cannot append" error in hf mf sniff d
- fixed hint on mfkey32 in hf mf sim x
- fixed hf mf sniff sometimes showing rogue data from previous calloc
- improve snooping/sniffing by syncing modulation detector window with reader signal (hi_iso14443a.v)
- code cleanup of hi_iso14443a.v
2014-03-25 21:38:24 +01:00
PenturaLabs 1801456ede Re-submitting Midnitesnake's Mifare Ultralight Patch 2014-03-18 14:02:32 +00:00
martin.holst@gmail.com 0c12504a5a Patch submitted by 'FireFart', for some issues with 'hf mf chk'. See http://www.proxmark.org/forum/viewtopic.php?id=1888 for more info 2014-02-27 18:10:12 +00:00
micki.held@gmx.de 7bc95e2e43 - fixed iso1443a ManchesterDecoder in order to fix broken Snoop/Sniff
- enhanced tracing: hf 14a list now shows meaningful timing information. With new option f it also shows the frame delay times (fdt)
- small fix for hf 14b list - it used to run into the trace trailer
- hf 14a sim now obeys iso14443 timing (fdt of 1172 or 1234 resp.)
Note: you need to flash FPGA as well.
More details in http://www.proxmark.org/forum/viewtopic.php?pid=9721#p9721
2014-02-19 20:35:04 +00:00
martin.holst@gmail.com d2f487af9c Various improvements on the Mifare1kSimulation. Fixed issue with tracebuffer not being cleared, fixed issue with 'static' errors, added modes for doing reader-only attack, added interactive mode, added possibility to set UID from cmdline, either 7-byte or 4-byte. See http://www.proxmark.org/forum/viewtopic.php?id=1529 and http://www.proxmark.org/forum/viewtopic.php?id=1649&p=3 for some more background and discussion 2014-01-31 21:17:34 +00:00
dn337t@gmail.com a00411152f use CLOCKS_PER_SEC instead of platform-specific hardcoded value 2013-10-22 12:14:32 +00:00
roel@libnfc.org 981bd4292e integrated MIFARE ultralight features, contributed by 'midnitesnake' 2013-10-11 08:43:23 +00:00
martin.holst@gmail.com 6a2c1d8e14 Minor issue, usability 2013-10-04 18:47:38 +00:00
martin.holst@gmail.com 05ed5c496a Made script-based default key check a bit more intelligent, so it works not only on 4k cards. Also added option to save data to a dump-file 2013-10-01 19:58:42 +00:00
micki.held@gmx.de 9492e0b098 Major rework of hf mf nested:
- PM: used GetCountMifare in MifareNested() for improved timing accuracy and to deliver better quality nonces
- PM: MifareNested now delivers exactly two different nonces to avoid time consuming multiple lfsr_recovery32() on client side
- Client: replaced quicksort by bucketsort in crapto1.c which is faster 
- Client: use multithreading (two parallel calls to lfsr_recovery32())
- Client: fixed a small bug in mfnested() (always showed trgkey=0)
- Client: introduced a mutex for PrintAndLog() to avoid interlaced printing
Minor rework of hf mf chk:
- Avoid time consuming off/on cycles. Send a "halt" instead.
2013-09-15 09:33:17 +00:00
micki.held@gmx.de 1c611bbd26 2013-07-08 17:56:05 +00:00
martin.holst@gmail.com e772353f72 Major changes to hf mf mifare 2013-06-26 21:13:02 +00:00
roel@libnfc.org 759c16b31f client should compile without warnings on linux, mac, windows 2013-03-14 15:03:04 +00:00
roel@libnfc.org 125a98a110 fixed stupid 64-bit formatting for x86/amd64 and unix/windows 2013-02-28 22:22:24 +00:00
roel@libnfc.org 7dd1908b24 fixed 'hf mf' command and some others 2012-12-07 22:37:22 +00:00
roel@libnfc.org 902cb3c00b major USB update 2012-12-04 23:39:18 +00:00
Merlokbr@gmail.com bfaecce6eb there was bug in hf mf mifare. and speed up this command. 2012-11-08 09:48:02 +00:00
dn337t@gmail.com e50d95165c removed dead check of uint8_t > 255 2012-08-13 19:52:22 +00:00
dn337t@gmail.com eede7162bc commented set but unread variable wantSaveToEml 2012-07-20 09:04:23 +00:00
Merlokbr@gmail.com 71d90e54cd hf mf sniff transfered parity from arm to decoding procedure 2012-07-17 15:19:15 +00:00
Merlokbr@gmail.com c948cbde8c small fix 2012-07-17 11:29:34 +00:00
Merlokbr@gmail.com e0c635d19c hf mf sniff - working with emulator files 2012-07-17 11:28:12 +00:00
Merlokbr@gmail.com 55acbb2a39 improved command hf mf sniff. Now it cant decode nested authentication and cant write emulator files 2012-07-16 14:49:51 +00:00
Merlokbr@gmail.com 39864b0bd4 "hf mf sniff" low level logics works. 2012-07-11 15:52:33 +00:00
Merlokbr@gmail.com b62a5a8444 small improvements, added new command hf mf sniff (there will be cool sniffer). But now... here is optimized hf 14a snoop. As I see it works the same as th old version. 2012-07-06 16:19:05 +00:00
douniwan5788 ac14bee321 Fixed auto nt bug 2012-07-06 13:44:37 +00:00