Commit graph

590 commits

Author SHA1 Message Date
Martin Holst Swende 1e1de234ac Merge pull request #121 from frederikmoellers/master
Add PACE replay functionality
2015-06-23 22:23:08 +02:00
Martin Holst Swende b8d34d0598 Merge pull request #118 from marshmellow42/master
fix t55xx write timing
2015-06-23 22:18:50 +02:00
pwpiwi 01b7a6a898 Merge pull request #114 from pwpiwi/iso14443b_fix
fixing iso14443b (issue #103): fix bug introduced during Bigbuf rework
2015-06-23 07:14:52 +02:00
pwpiwi 705bfa1058 fixing iso14443b (issue #103):
- increased DMA_BUFFER_SIZE to avoid occasional circular buffer overflows.
- minor code cleanups
2015-06-22 22:03:43 +02:00
Frederik Möllers 3bb07d96c8 Add PACE replay functionality
This function allows the user to specify APDUs which are sent to a card
supporting the PACE protocol. The response times are measured and
printed.
The code was pulled from the old Google Code repository (branch "epa")
and modified to fit into the new code base.
2015-06-22 14:20:13 +02:00
pwpiwi 467340996e fixing iso14443b (issue #103):
- fix hf 14b snoop
- fix hf 14b sim
2015-06-21 18:04:24 +02:00
pwpiwi da586b1702 fixing iso14443b (issue #103):
- revert removal of FPGA_HF_READER_RX_XCORR_848_KHZ. Need to be able to switch to 424kHz for ISO15693.
2015-06-18 15:41:30 +02:00
pwpiwi 50365fedcb fix issue #116: remove includes of stdio.h in armsrc 2015-06-18 11:33:53 +02:00
pwpiwi 132a02179c fixing iso 14443b (issue #103):
- fix: treat empty commands as error
- deleting dead code
- rename USB-Commands (ISO14443 -> iso14443B)
2015-06-18 09:49:22 +02:00
pwpiwi d5875804a3 fixing iso14443b (issue #103):
fix: don't waste time to calculate parity bits. Instead add void parity bits to trace and ignore them on client side
2015-06-18 07:56:08 +02:00
pwpiwi 51d4f6f114 fixing iso14443b (issue #103):
- fix: IQ demodulator (FPGA)
- fix: approximately align reader signal delay to tag response delay (FPGA)
- fix: remove deprecated RSSI calculation to improve decoder speed (iso14443b.c)
- fix: better approximation of signal amplitude to avoid false carrier detection (iso14443b.c)
- fix: remove initial power off in iso14443b raw command (iso14443b.c)
- add: enable tracing for iso14443b raw command (iso14443b.c)
- fix: client crashed when checking CRC for incomplete responses (iso14433b.c)
- speeding up snoop to avoid circular buffer overflow
- added some comments for better documentation
- rename functions (iso14443 -> iso14443b)
- remove unused code in hi_read_rx_xcorr.v
2015-06-17 20:27:36 +02:00
marshmellow42 4a3f1a3793 revert t55xx start gap and write timing changes
also noted specs in comments
2015-06-11 23:52:40 -04:00
pwpiwi 09c66f1f09 fixing iso14443b (issue #103): fix timing issue (speeding up
the decoders)
2015-06-03 13:28:28 +02:00
pwpiwi 5b95953d42 fixing iso14443b (issue #103):
- most significant bit of tag data (which happens to be the sign bit)
had been dropped when snooping (FPGA change)
- avoid trying to decode both tag and reader data when snooping (we don't
have the time to do so).
2015-06-02 22:50:16 +02:00
pwpiwi 67ac4bf75c fix issue #103: revert type change. Samples from FPGA are signed.
Renamed iso14443.c to iso14443b.c
2015-06-02 07:28:47 +02:00
pwpiwi 0d9a86c724 Fix issue #103 (hopefully). Quite an old bug which was previously
masked by a big DMA_BUFFER_SIZE.
2015-06-01 19:47:21 +02:00
marshmellow42 e35031d2b7 MFU code cleanup - final ?
fixed bug in debug print in MF 1k sim.
2015-05-27 17:21:42 -04:00
marshmellow42 4973f23d3c clean up mfu device side code
+ add xor calc to util (prep for desfire)
commented out MifareUWriteBlockCompat as it isn't used in client
currently (it is a command we could support..  but why?)
relabeled a few device side mfu functions to be clearer.
2015-05-27 12:24:13 -04:00
pwpiwi 8e074056ac also delete *.bin and fpga_compressor when "make clean".
Add target to make fpga_compressor when client is not yet compiled.
Get version information and cache it when client starts (avoids clearing
BigBuf when calling hw version).
Add some comments and remove debugging printouts.
Add version info and ChangeLog in modified zlib.
2015-05-26 18:12:40 +02:00
marshmellow42 22342f6dfe Add clearCommandBuffer before SendCommand
adjust output of mfu rdbl to be consistent
fix output of mfu dump in case startPage was specified. (also was
missing "i" in second print...)
2015-05-26 10:40:23 -04:00
pwpiwi 0fa01ec7da Compress the .data section as well (saves another 4KBytes and comes for free)
zlib tuning: prevent fpga_compress from generating fixed code blocks
armsrc/Makefile: replace osimage with fullimage
2015-05-26 08:31:32 +02:00
pwpiwi 28b9faccea Tailor zlib to our needs:
- disable support for fixed code blocks. Saves 2KByte code tables in ARM Flash memory
2015-05-26 08:31:30 +02:00
pwpiwi fb22897415 fpga_compress: interleave (combine) fpga_lf.bit and fpga_hf.bit before compression.
fpga_loader.c: change to unweave fpga_lf and fpga_hf accordingly
prepare fpga_compress, fpga_loader and Makefile to handle more than two FPGA config files
revert removal of fullimage Makefile target. Remove osimage instead.
2015-05-26 08:31:28 +02:00
pwpiwi f39198789b replaced gzip with an own compressor tool (fpga_compress.c, based on zlib)
This allows to remove the gzip header support and the z_crc32.[ch] files
(which saves more than 2KBytes of the ARM's flash memory)
2015-05-26 08:31:26 +02:00
pwpiwi 25056d8b47 Finish support for compressed FPGA images in fpgaloader.c
- move zlib source files to separate directory zlib
- rename zlib/crc32.[ch] to zlib/z_crc32.[ch]
2015-05-26 08:31:24 +02:00
pwpiwi add4d47046 add: compress fpga images during compile, uncompress at run time 2015-05-26 08:31:21 +02:00
pwpiwi e61530408c add: hw ver: show FPGA versions for both HF and LF FPGA configs
add: hw ver: show used and free flash memory
chg: prepare fpgaloader for compressed FPGA configs
2015-05-26 08:31:19 +02:00
marshmellow42 79d7bcbb51 updated mfu rdbl and wrbl commands
@iceman1001 s rdbl and wrbl cmd updates.
dump screen output adjusted
2015-05-24 22:28:21 -04:00
marshmellow42 0ce03d9ab0 fix mfu dump getbigbuffer bug
Thanks @iceman1001 for catching my oops, and fixing it :)
2015-05-23 22:35:50 -04:00
marshmellow42 d7acc6403e hf mfu dump - bigbuf allocation fix
some larger nfc tags can get large so set the allocation to the 4k
CARD_MEMORY_SIZE buffersize.
2015-05-19 11:30:50 -04:00
marshmellow42 29250969b0 @iceman1001 s comments/updates mfu cmds 2015-05-18 22:07:11 -04:00
marshmellow42 9d87eb6650 MF ultralight code cleanup 2015-05-18 13:11:00 -04:00
marshmellow42 8258f40969 Iceman1001 s MFU clean up
cleaned up MF UL_C auth code device side.
2015-05-17 20:49:25 -04:00
marshmellow42 cceabb79e6 mfu info / dump attempt at missing auths
NOT TESTED.  will test soon.  probably has bugs!
2015-05-16 01:00:31 -04:00
marshmellow42 2b3af97df2 various bug fixes 2015-05-13 11:07:47 -04:00
marshmellow42 6ce0e5386a HF Search - refactoring cmds to work with it 2015-05-12 16:45:48 -04:00
marshmellow42 75377d29d6 MFU - Icemans further improvements
add UL-C device side read card with authentication
add MF_UL-Annotations
add ntag, and more ul descriptions in hf mfu info
2015-05-06 00:55:29 -04:00
marshmellow42 b3125340f3 Icemans UL-C Auth dev side fix plus a few other ...
... small UL fixes
2015-05-03 15:41:11 -04:00
marshmellow42 92690507ab Iceman's updates to MFU info and dump 2015-04-30 09:28:43 -04:00
marshmellow42 f168b2633b MF Ultralight - Iceman's updates + mine
Beginning of Ultralight additions.
detection of Ultralight Types added
dump command now auto detects type
can authenticate Ultralight C
2015-04-29 18:27:31 -04:00
marshmellow42 e9b8d0dd6e Iceman's mf sim 7bt UID fix from #97 2015-04-28 15:43:58 -04:00
marshmellow42 25d3e5cc83 Merge remote-tracking branch 'upstream/master' 2015-04-08 14:19:19 -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 fef74fdce4 lf ask consolidation
backend:
askman and askraw demods merged into askdemod (args adjusted
accordingly)
re-arranged lfdemod.h in alphabetical order and by category

front end:
data detectclock a (ask) now also reports the selected best start
position for demod
data manrawdecode takes an invert arg now
2015-04-08 01:07:39 -04:00
pwpiwi 6306ff4bac Merge branch 'master' into topaz
Conflicts:
	armsrc/Makefile
	client/Makefile
2015-04-05 19:45:59 +02:00
pwpiwi f83c41c75b Merge pull request #89 from pwpiwi/image_shrink
Reclaim more than 19K of ARM flash memory.
2015-03-31 22:57:33 +02:00
Martin Holst Swende d5d6f22718 Merge pull request #91 from marshmellow42/master
lfdemod.c refactoring  (+ bug fixes)
2015-03-31 22:11:19 +02:00
pwpiwi e335ca2846 Reclaim more than 19K of ARM flash memory.
- added compiler options -fdata-sections and -ffunction-sections (thanks to iceman for the hint)
- removed float operations from common/lfdemod.c to avoid adding float libraries to the ARM os image
- moved the fpga images to the data section to avoid reserving unused space for a separate section
2015-03-31 08:07:26 +02:00
Martin Holst Swende caaf9618ae Minor mod to 'hf iclass read', it now also reads and prints the configuration of the tag found 2015-03-29 21:49:58 +02:00
marshmellow42 2eec55c8a4 lfdemods streamline & bug fixes
removed duplicate code countPSK_FC - adjusted countFC to work.
bug fixes & streamlined code in:
lf hid fskdemod
lf em em410xdemod

cleaned up lfdemod.c some
2015-03-27 00:02:30 -04:00
marshmellow42 e0165dcf3a Fixed indents to Tabs from Spaces
Spacing changes ONLY - no code changes
2015-03-25 14:24:36 -04:00
marshmellow42 327a690813 EM410x bug fix 2015-03-24 23:05:46 -04:00
marshmellow42 1fbf895616 lf updates
applies icemans full ata55x7 read/write settings
adds checksum to ioprox (thanks to iceman)
adds silent mode for lf read and getSamples
fix lf em em410xwatch and lf em410xspoof
improve data rawdemod ar -  for biphase demods
improve detectclock a for strong antennas
2015-03-23 16:29:50 -04:00
marshmellow42 13d77ef964 lf t5 read plus lf demod adjustments
lf t5xx commands updated from ICEMAN
lf em410x commands updated
lf search bug fix for 2 args
test scripts from iceman
lf demod:
better ask clock detection with Strong fully clipped waves
better ask raw demod with strong fully clipped waves
fsk demod add back in skipped bits during demod
nrz demod add back in skipped bits during demod
2015-03-22 15:28:48 -04:00
pwpiwi 48ece4a750 add: Topaz mode for "hf 14a raw" (new option -T)
chg: allow tracing without parity
chg: make "hf list topaz" aware of additional commands for Dynamic Memory Model
2015-03-20 21:06:51 +01:00
pwpiwi 05ddb52c43 fix: introduced a stupid error when refactoring the start bit detector in MillerDecoding()
chg: use -O2 instead of -Os when compiling ARM sources
chg: don't clear the Miller decoders input buffer on reset
chg: be more specific for the Miller decoders start bit pattern
add: new option c in hf list: mark CRC bytes (default is off)
2015-03-18 18:32:43 +01:00
pwpiwi ef00343cb1 revert change "hf list topaz" to "hf list nfc"
refactored Startbit detection in MillerDecoding()
relaxed startbit detection in MillerDecoding()
fixed CRC checking and CRC bytes marking in hf list
fixed topaz multi frame command listing in hf list topaz
2015-03-17 07:41:08 +01:00
marshmellow42 b41534d142 adjust ask/biphase handling - more complete
also added XL EM410x formats
2015-03-15 22:03:50 -04:00
pwpiwi a8904ebd46 Change "hf list topaz" to "hf list nfc"
fix: reduce length of expected unmodulated signal in Miller decoder in order
to allow decoding of NFC reader communications
add: hf list nfc: aggregate reader commands into one line
add: hf list nfc: CRC check for NFC communications
2015-03-15 16:49:09 +01:00
pwpiwi ee1eadee0f add: start to support Topaz tags
- hf 14a reader now exits gracefully in case of proprietary anticollision sequence
- changed miller decoder to handle Topaz 8 data bits/no parity frames from reader
- started to implement hf list topaz
2015-03-13 18:13:18 +01:00
Martin Holst Swende f7048dc8a9 Implemented usb_poll() within LF sim. This means the LF sim will be aborted whenever something comes over the USB 2015-03-12 16:32:01 +01:00
pwpiwi 04bc1c660b fix: hf 14a raw was broken
(see http://www.proxmark.org/forum/viewtopic.php?id=2351)
2015-03-11 20:19:30 +01:00
marshmellow42 ada339a10f biphase bug fixes 2015-03-09 15:27:20 -04:00
marshmellow42 712ebfa6df 1 bug fix + code trimming 2015-03-07 23:31:23 -05:00
marshmellow42 df51693f95 Merge remote-tracking branch 'upstream/master' 2015-03-06 12:30:16 -05:00
marshmellow42 78f5b1a77c lf sim fixes/creations correct now
fixed lf simpsk
fixed lf em em410xsim
fixed lf sim  (can go right from lf search to lf sim if you have a
strong antenna - if not use a demod first)
2015-03-06 12:28:54 -05:00
marshmellow42 e09f21fa7b Revert "lf sim fixes/creations"
This reverts commit 293de1bad7.
2015-03-06 12:26:33 -05:00
marshmellow42 293de1bad7 lf sim fixes/creations
fixed lf simpsk
fixed lf em em410xsim
fixed lf sim  (can go right from lf search to lf sim if you have a
strong antenna - if not use a demod first)
2015-03-06 12:25:36 -05:00
ikarus 9cefee6f42 Fixed issue #36 & improved file consistency. 2015-03-04 11:00:39 +01:00
marshmellow42 39676885b4 Merge remote-tracking branch 'upstream/master' 2015-03-03 20:44:37 -05:00
Martin Holst Swende c8387e85e3 iClass full simulation of tags now officially works, with some cheating regarding reader update and write commands 2015-03-02 21:30:22 +01:00
marshmellow42 8d960002c8 lf cmds fix, add, show
show command to UI:
data printdemodbuffer - allow printing of demod buffer
Add:
data askgproxiidemod - demod a gproxii tag

Fix:
adjust lf simxxx commands further for testing
2015-03-02 14:42:55 -05:00
Martin Holst Swende e5cd4ee4b4 Tag MAC finally works! (Full sim not yet, though) 2015-03-02 20:14:35 +01:00
Martin Holst Swende 61fe90736b Implemented the correct way to calculate MAC from a tag, feeding it an extra 32 zeroes. Also divided it up into two parts, one of which can be precalculated by the device before the simulation begins 2015-03-02 00:38:36 +01:00
marshmellow42 73da818743 lf simulation tests
added SimulateTagLowFrequencyTest function
with some adjustments that help ASK simulations
FSK and PSK still need help.  Left original HID sim alone as for some it
may partially work.
2015-02-28 14:33:05 -05:00
Martin Holst Swende c99dc845b1 Added the ciphers also.. doh 2015-02-27 20:19:10 +01:00
Martin Holst Swende 10a8875c72 Implemented new optimized version of MAC-calculation for iclass 2015-02-26 20:35:35 +01:00
marshmellow42 872e3d4d6f NEW lf simpsk 2015-02-21 21:36:02 -05:00
Martin Holst Swende b19caaefc2 Fixed minor bugs in iclass fullsim, does not work yet though 2015-02-21 20:47:40 +01:00
marshmellow42 40148ab609 Merge remote-tracking branch 'upstream/master' 2015-02-19 21:38:17 -05:00
marshmellow42 abd6112fc4 Revert "Revert "lf simask, lf simfsk and bug fixes""
This reverts commit e396001c47.
2015-02-19 21:35:34 -05:00
marshmellow42 e396001c47 Revert "lf simask, lf simfsk and bug fixes"
This reverts commit fb0c84c3df.
2015-02-19 21:22:05 -05:00
marshmellow42 fb0c84c3df lf simask, lf simfsk and bug fixes 2015-02-19 21:21:11 -05:00
Martin Holst Swende 1defcf606f More work on iclass full simulation, and some work on iclass tag dump parsing 2015-02-19 10:48:33 +01:00
Martin Holst Swende b67f7ec359 Further implementation of iclass 'fullsim'. Moved protocol definitions to shared file. Had to add some loclass-function to arm-side to support authentication in fullsim mode 2015-02-18 20:02:44 +01:00
Martin Holst Swende e80aeb9695 Started iclass emulator support on device side. Not functional yet 2015-02-14 21:30:26 +01:00
Martin Holst Swende 428d622160 Fixed bug with iclass dump which prevented saving to file 2015-02-14 20:42:23 +01:00
Martin Holst Swende 0cd2a41ac0 Made 125KHz default sampling, instead of 134KHz for LF 2015-02-14 19:55:23 +01:00
pwpiwi 19a700a8b5 hf 14a: if the tag supports it, set default timeout according to ATS
hf epa: remove explicit but arbitrary timeout settings
Bugfix: don't timeout when frame transmission has already started
2015-02-11 22:20:22 +01:00
Martin Holst Swende 61972abbdd Merge branch 'master' into GenericTracing
Conflicts:
	armsrc/iso14443a.c
2015-02-10 21:25:14 +01:00
Martin Holst Swende 904a96cd80 Merge pull request #59 from marshmellow42/master
lf demod additions/fixes
2015-02-09 20:28:12 +01:00
pwpiwi 0c8d25ebd8 Fixed: hf mf sim failed on fast reader responses
In Miller Decoder: don't wait too long for a stable signal
In Miller Decoder: Don't accept sequences of four or more zeroes as start bit
In EmSendCmd14443aRaw: don't wait for emptying the FPGA delay queue if it isn't filled
2015-02-09 06:51:04 +01:00
Martin Holst Swende beefe5bc4d Minor dox 2015-02-07 21:22:53 +01:00
Martin Holst Swende 665775c844 Some documentation and formatting to LogTraceHitag 2015-02-07 21:05:14 +01:00
Martin Holst Swende aabb719dc4 Moved LogTraceHitag to BigBuf (no changes to the function ... yet) 2015-02-07 20:55:17 +01:00
Martin Holst Swende 3000dc4e7e Generic tracing; removed iso14a_XX-functions, removed traceLen as global varible 2015-02-07 20:49:40 +01:00
pwpiwi 3b692427ac Bugfix hw tune, hf tune: voltage measures were VERY wrong
Modified hw detectreader: display reader field strength in mV units and to be less phony
2015-02-07 10:14:49 +01:00
marshmellow42 be2cf126bf Merge remote-tracking branch 'upstream/master' 2015-02-06 14:45:46 -05:00
Martin Holst Swende 7d5ebac993 Merge branch 'master' into GenericTracing
Conflicts:
	armsrc/iso14443.c
	armsrc/iso14443a.c
	client/cmdhf.c
	client/cmdhf14b.c
2015-02-06 08:41:02 +01:00
marshmellow42 e770c64824 lf psk/nrz split, add maxErr argument
changed psk to use wave lengths instead of peaks
split out NRZ from psk demod
added maxErr argument to raw demods (except fsk)
2015-02-05 17:01:18 -05:00
Martin Holst Swende bb42a03ef1 Fix #1 for pm3 iclass simulation, remove erroneous extra bit after transmission 2015-02-05 19:40:47 +01:00
Martin Holst Swende 0644d5e3a3 Merged with master 2015-01-31 18:21:38 +01:00
Martin Holst Swende 31abe49fd3 Some more fixes to longer lf recordings. Now also supports longer snoops, and an additional command 'lf config' has been defined, instead of having to specify all params for every call 2015-01-30 23:03:44 +01:00
Martin Holst Swende b3cc5f2987 Reverted erroneous commit from bigbuf-rework 2015-01-29 19:58:46 +01:00
Martin Holst Swende f6d9fb173f Added client-side support for recording longer samples, fixed last (?) issues on device-side 2015-01-29 00:57:22 +01:00
marshmellow42 0892b968ce fix hid prox standalone bug
Fixed standalone bug by re-making the function return the hi and lo
values. (used only by samyrun function in appmain.c)
2015-01-28 12:55:04 -05:00
marshmellow42 08ebca682c lf hid fskdemod bug
re-introduced in last bigbuf changes
2015-01-28 11:45:31 -05: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
pwpiwi 117d9ec25c Refactoring of BigBuf handling in order to prepare for more efficient memory allocation and longer traces. 2015-01-27 22:25:55 +01:00
marshmellow42 a1d17964a2 lf demod bug fix & refactor
fixed bug in lfops.c in hid fskdemod
refactored data fskXXXDemods for specific tags to use more common code.
2015-01-27 14:51:12 -05:00
Martin Holst Swende 16b75f27c3 Minor tweaks to iso14443b snoop tracing 2015-01-27 16:34:11 +01:00
Martin Holst Swende 03dc174036 Minor refactoring 2015-01-27 09:06:01 +01:00
marshmellow42 9c0f13d5dd Merge remote-tracking branch 'upstream/master' 2015-01-26 17:07:49 -05:00
Martin Holst Swende aeadbdb216 Generic tracing: Some fixes in iso14443b snooping, to how DMA access is performed, sizes and buffers. 2015-01-26 22:10:05 +01:00
Martin Holst Swende 7c676e7269 Some documentation 2015-01-26 21:15:28 +01:00
Martin Holst Swende 7242efa07c bugfix 2015-01-22 23:04:59 +01:00
Martin Holst Swende cb366e9dbd Added a lf acquisition-mode which can do decimation and quantization, in order to be able to record longer transactions 2015-01-22 23:01:29 +01:00
Martin Holst Swende 9e8255d4e9 Generic tracing pt.3 : reworking how iso14443b-traces are stored in ARM-memory 2015-01-21 23:53:40 +01:00
marshmellow42 ec75f5c10a lf Bug Fixes and lf demod additions
added data fskparadoxdemod
added data setdebugmode (for demods)
added data shiftgraphzero (to help clean weak reads)
fixed a few bugs with the data detectaskclock
added data fskfcdetect to detect FSK clocks
adjusted most of my demods to put raw tag binary to demod buffer for
future sim and clone commands (psk still needs work)
2015-01-20 17:28:51 -05:00
iceman1001 c8b6da2295 Merge branch 'master' of https://github.com/holiman/proxmark3
Conflicts:
	armsrc/appmain.c
	armsrc/apps.h

Step 1 for the Ultralight / Ultralight-c
2015-01-20 20:59:24 +01:00
iceman1001 5149e37e66 Merge branch 'master' of https://github.com/Proxmark/proxmark3
Conflicts:
	armsrc/appmain.c
	armsrc/apps.h
2015-01-20 09:32:53 +01:00
Martin Holst Swende 355c8b4a7d Generic trace pt2: made iso14443b use standard trace format 2015-01-18 20:23:58 +01:00
Martin Holst Swende 80fe723570 Generic trace pt1: Moved arm-side trace functionality into util-package 2015-01-18 20:21:53 +01:00
Martin Holst Swende f164662363 Merge branch 'master' of https://github.com/iceman1001/ForPm3
Conflicts:
	armsrc/appmain.c
	armsrc/apps.h
2015-01-15 21:50:03 +01:00
Martin Holst Swende 758f1fd1f3 Fixed issue #43 on github 2015-01-15 16:07:58 +01:00
Martin Holst Swende 6b038d192a Minor dox 2015-01-15 15:45:54 +01:00
Martin Holst Swende 1eb874ee3f Merge branch 'master' of github.com:Proxmark/proxmark3 2015-01-15 15:45:15 +01:00
Martin Holst Swende 7b941c8d7f Fixed memory corruption after reader-attack in armsrc, fixed annoying LED 2015-01-15 15:27:44 +01:00
Martin Holst Swende 645c960f61 Implemented new FPGA mode for iclass tag simulation. Reduces arm-side size of transfer/memory by a factor of 8. Makes for easier arm-side encoding of messages, for when we start needing to do that on the fly instead of using precalculated messages 2015-01-15 15:16:34 +01:00
iceman1001 a631936e84 ADD: Midnitesnaks's & Pentura labs Ultralight-c modifications in ARMSRC.
ADD:  des.c  ,  aes.c  in ARMSRC
2015-01-13 23:18:04 +01:00
Martin Holst Swende 55eaed8f2a Documentation to apps.h, documentation/renaming to iclass 2015-01-12 22:08:57 +01:00
Martin Holst Swende f44a01235c Merge branch 'master' of https://github.com/iceman1001/ForPm3 2015-01-09 21:50:36 +01:00
iceman1001 952a8bb59b Merge branch 'master' of https://github.com/Proxmark/proxmark3
Conflicts:
	armsrc/lfops.c
	client/cmddata.c
	client/graph.c
2015-01-08 22:23:45 +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
marshmellow42 ba1a299ce6 code cleanup. re-added psk commands.
also fixed a bug in detect clock functions.
sync with master prep for pull request
2015-01-07 18:14:27 -05:00
marshmellow42 c07b79fcbf sync with master lf files to resolve conflicts 2015-01-07 18:13:27 -05:00
marshmellow42 4118b74dc8 added data psk* cmds for pskdemod
fixed a couple small bugs in other lf functions as well including
detectaskclock,  stopped changes from being made to graphbuffer.
2015-01-07 18:13:26 -05: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 024b97c507 Merge branch 'master' of https://github.com/Proxmark/proxmark3
Conflicts:
	client/cmdhf.c
2015-01-07 22:55:26 +01:00
iceman1001 d91a31f935 CHG: minor code clean up.
ADD: tunesamples in cmddata.c  pullrequest #33,  was removed by Marshmellows other commits. I returned it.
2015-01-07 21:29:38 +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 4888b28195 Merge branch 'master' of https://github.com/Proxmark/proxmark3 2015-01-07 11:09:05 +01:00
Martin Holst Swende cb29e00a12 Save iclass dumps to file, like mifare-dump functionality works 2015-01-07 09:57:18 +01:00
iceman1001 9484ff3d6e ADD: tnp3xxx identification in luascripts.
CHG: minor code clean up.
2015-01-06 21:20:41 +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
Martin Holst Swende 39d3ce5dd6 Moved iclass crc to be based on a lookup table 2015-01-04 22:10:25 +01:00
Martin Holst Swende c8dd9b092e Some work on iclass dump and iclass list, now the dumping is a lot more stable. I think the comms should be measured and tuned a bit more, right now it kind of works thanks to retry-functionality, but the retries are probably not needed if we are a bit more careful about timing, so we don't send commands too fast for the tag to handle 2015-01-04 14:53:26 +01:00
Martin Holst Swende 2e9d4b3ff4 Some work on iclass, started on some better support in 'hf iclass list' and also fixes to 'hf iclass reader' so it exits better when the button is pressed 2015-01-03 15:11:48 +01:00
Martin Holst Swende 854b9a233f Removed unused variable 2015-01-03 14:29:07 +01:00
Martin Holst Swende ae8e8a4372 Corrected indentation to tabs only 2015-01-03 14:21:07 +01:00
Martin Holst Swende 6ca4c6463e Removed wrong size-count, sizeof(bigbuf) would always return 40000 in lfops 2015-01-03 14:17:59 +01:00
marshmellow42 f822a063b3 lf demod code cleanup - added fskraw arguments
merged code and added arguments to data fskrawdemod to allow other fsk
mode demodulations (FSK2a = RF/10 & RF/8) another might be (RF/8 & RF/5)
2014-12-31 02:27:30 -05:00
marshmellow42 6bfa18eab4 Merge pull request #1 from Proxmark/master
Test
2014-12-29 16:14:23 -05:00
marshmellow42 66707a3b3c LF Demod bug fixes and add lf em em410xdemod
fixed a few bugs in lf demod that the streamlining added.  added new lf
em em410xdemod command that loops until button pressed. (similar to lf
hid fskdemod
2014-12-29 15:32:53 -05:00
marshmellow42 7db5f1ca25 slight adjustment to include
removed extra unneeded path
2014-12-28 21:29:33 -05:00
marshmellow42 eb191de615 LF Demod streamlining
one shared location for demoding lf for arm and client.  also added a
few raw demod commands.
2014-12-28 20:33:32 -05:00
pwpiwi 52bfb95543 bugfixes in iso14443a.c and hf 14a reader
- introduced with the big frame and parity support (commit 6a1f2d82): tag responses with len%8 == 0 were dropped  - thanks iceman for testing and finding
- after unsuccessful hf 14a reader the field stayed on. Thanks to iceman for proposing the fix.
2014-12-23 11:21:42 +01:00
marshmellow42 b3b706693b Final touches on IO prox and HID prox demod
makes both more robust and handles various error situations.
2014-12-19 12:14:27 -05:00
pwpiwi db4de4d82f Merge branch 'master' of https://github.com/Proxmark/proxmark3 2014-12-18 19:42:49 +01:00
pwpiwi 57642f63fa bugfixes hf epa cnonces
- extended length (more than 1 byte) not handled correctly
- nonces not printed on Windows due to type mismatch
2014-12-18 19:40:35 +01:00
Martin Holst Swende 7496d8d822 Merge pull request #32 from marshmellow42/master
Fixes and additions to lf io fskdemod  and addon parameter to lf hid fskdemod
2014-12-18 08:56:26 +01:00
pwpiwi 2bdd68c370 unify/refactor hw tune and data tune
- unified hw tune and Enio's great data tune
- don't use BigBuf (and hardcoded Offset)
- removed special handling of CMD_MEASURED_ANTENNA_TUNING
  in UsbCommandReceived()
2014-12-17 20:57:26 +01:00
marshmellow42 083ca3de73 LF HID & IO prox fixes/options 2014-12-17 09:51:40 -05:00
pwpiwi 471c514167 Merge branch 'master' of https://github.com/Proxmark/proxmark3 2014-12-16 07:47:02 +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 6116c79618 Reverted to original malicious CSNs from paper, it appears legit readers does not accept if they dont end with F7,FF,12,E0 2014-12-14 21:37:56 +01:00
Martin Holst Swende eabba3df7e Fix (iclass) 2014-12-14 18:07:12 +01:00
marshmellow42 4860172789 LF HID & IO prox demod translation addons
lf hid fskdemod - add bit format length, facility code and card numbers
for different formats
2014-12-13 20:23:59 -05:00
Martin Holst Swende d6a120a25b Added Enios cool tuning-trick (LF) from forum-post: http://www.proxmark.org/forum/viewtopic.php?pid=13060#p13060 2014-11-30 22:30:36 +01:00
Martin Holst Swende ca4714cd23 More coverity fixes 2014-10-30 21:49:18 +01:00
Martin Holst Swende 2ed270a854 Coverity-fixes in armsrc 2014-10-28 21:44:17 +01:00
Martin Holst Swende 9cc8a1e588 Some more docs, also made lf hid fskdemod a bit more stable. Should be no more false readings now 2014-10-25 22:42:27 +02:00
Martin Holst Swende b225678574 Some minor changes and some documentation 2014-10-24 21:12:31 +02:00
Martin Holst Swende 1a5a0d7590 Fixed compilation issues, but functionality not tested 2014-10-24 20:53:43 +02:00
Martin Holst Swende f97d4e2378 First try att merging with head 2014-10-24 20:46:02 +02:00
Martin Holst Swende e6ee6c4cd1 Merge remote-tracking branch 'origin/master' into PenturaLabs-iclass-research 2014-09-19 09:45:38 +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 bfb6a143ea bugfix hf mf sim
- an additional erronous byte was sent after SAK
2014-08-05 18:40:19 +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
pwpiwi c7324bef28 Bugfix hf 14a raw:
number of bits sent was wrong when option -c was used without option -b
2014-07-01 08:28:28 +02:00
Martin Holst Swende 9b82de75f4 more work towards iclass elite dumping.. not quite finished yet though :( 2014-06-30 00:20:40 +02:00
Martin Holst Swende aa41c6058a Merged two iclass-reader functions into one to remove duplicated code, update loclass library with hash2 algo 2014-06-29 23:34:24 +02:00
Martin Holst Swende dbf732ee41 Minor 2014-06-29 13:48:13 +02:00
Martin Holst Swende 26c0d833ac Some minor changes [iclass-related] 2014-06-28 22:57:48 +02:00
Martin Holst Swende 3ad48540d4 Merge branch 'iclass-research' of https://github.com/PenturaLabs/proxmark3 into PenturaLabs-iclass-research
Conflicts:
	README.txt
	armsrc/apps.h
	client/Makefile
	client/cmdhficlass.c
	client/cmdhficlass.h
2014-06-28 20:52:37 +02:00
Martin Holst Swende 6db28145ea Merge remote-tracking branch 'origin/master' into iclass-fixes 2014-06-28 12:47:40 +02:00
iZsh 3b2fee43ea New LF edge detection algorithm + lowpass filter
This is a new LF edge detection algorithm for the FPGA.

- It uses a low-pass IIR filter to clean the signal
(see https://fail0verflow.com/blog/2014/proxmark3-fpga-iir-filter.html)
- The algorithm is able to detect consecutive peaks in the same
  direction
- It uses an envelope follower to dynamically adjust the peak thresholds
- The main threshold used in the envelope follower can be set from the ARM side

fpga/lf_edge_detect.v,
fpga/lp20khz_1MSa_iir_filter.v,
fpga/min_max_tracker.v: New file.

fpga/lo_edge_detect.v, fpga/fpga_lf.v: Modify accordingly.

armsrc/apps.h (FPGA_CMD_SET_USER_BYTE1,
FPGA_CMD_SET_EDGE_DETECT_THRESHOLD): New FPGA command.
fpga/fpga_lf.v: Modify accordingly/Add a 8bit user register.

fpga/fpga_lf.bit: Update accordingly.

fpga/tests: New directory for testbenches

fpga/tests/Makefile: New file. It compiles the testbenches
and runs all the tests by default (comparing with the golden output)

fpga/tests/tb_lp20khz_1MSa_iir_filter.v,
fpga/tests/tb_min_max_tracker.v,
fpga/tests/tb_lf_edge_detect.v: New testbenches

fpga/tests/plot_edgedetect.py: New script to plot the results from
the edge detection tests.

fpga/tests/tb_data: New directory for data and golden outputs
2014-06-27 14:27:03 +02:00
Martin Holst Swende 42f57e0294 Merged with master 2014-06-27 13:16:31 +02:00
iZsh b014c96d68 new command "lf snoop" to snoop raw ADC values
fpga/lo_read.v (lf_field): new argument.
fpga/fpga_lf.v: modify accordingly.

armsrc/apps.h (FPGA_MAJOR_MODE_LF_READER): Rename as FPGA_MAJOR_MODE_LF_ADC.
armsrc/apps.h (FPGA_LF_ADC_READER_FIELD): New LF option.
armsrc/lfops.c: Modify accordingly.

client/cmdlf.c (CmdLFSnoop): New command.
armsrc/appmain.c, armsrc/lfops.c, client/cmdlf.h, include/usb_cmd.h: Modify accordingly.
2014-06-21 21:33:54 +02:00
iZsh 62638f87db armsrc/fpgaloader.c: forgot the copyright notice 2014-06-20 12:29:58 +02:00
iZsh 7cc204bff8 THIS REQUIRES A BOOTROM UPDATE!! To save FPGA area, split the LF and HF bitstreams and load them on-demand. 2014-06-20 01:02:59 +02:00
penturalabs fecd8202a5 implemented 'hf iclass dump xxxx',
all you need is the magic key to dump contents of an iclass card
2014-06-17 10:55:37 +01:00
Martin Holst Swende 9f6e9d1575 More work on iclass simulation attack 2014-06-16 21:27:12 +02:00
Martin Holst Swende fa541aca96 Minor changes, it may actually work now, need to test with a credentialed reader 2014-06-07 22:16:57 +02:00
Martin Holst Swende 94ad01bfba Merged with head 2014-06-07 22:04:27 +02:00
Martin Holst Swende 81012e670b debug in progress 2014-06-07 22:00:31 +02:00
Martin Holst Swende e3dc1e4cf5 Minor changes in iclass.c 2014-06-07 21:49:56 +02:00
Martin Holst Swende 83fd67ba0b Added mode for 424k modulation (iso 15693) 2014-06-07 21:40:47 +02:00
Martin Holst Swende fdcd43eb15 Fixed (?) http://www.proxmark.org/forum/viewtopic.php?id=1967, two bytes are discarded when adding crc and sending raw iso14443a commands 2014-04-26 16:15:16 +02:00