Commit Graph
23434 Commits
Author SHA1 Message Date
Niel Nielsen d8537a1a6c Conditionalize PM3_CMD_DATA_SIZE based on device
Signed-off-by: Niel Nielsen <nieldk@gmail.com>
2026-09-01 17:57:31 +02:00
Paul KilarandClaude Opus 5 1a6255ad84 hf 14b: scale the WTX timeout, do not scale the shift
A card that needs longer than FWT to answer replies with S(WTX) carrying a
multiplier, and ISO 14443-4 has the timeout become FWT * WTXM for that
exchange. iso14443b_apdu() multiplied the shift instead:

    uint32_t fwt_temp = (s_iso14b_fwt * wtxm);
    iso14b_set_timeout((32 << fwt_temp));

(32 << fwi) is the FWT in ETUs - the form iso14b_set_fwt() uses, and the
one the client prints in hf 14b info - so this computed 32 << (fwi * wtxm).
With the fwi of 8 that a passport reports, wtxm 1 happens to come out
right, wtxm 2 is 256 times too long, and wtxm 4 shifts a uint32_t by 32.
That is undefined, and on ARM it leaves 0, so the read that follows gives
up before the card has answered and the client reports

    APDU: no APDU response

Found on a Polish ePassport that would not read. Every short command
answered - SELECT, an unsupported instruction, a malformed MSE - and only
MSE:Set AT with P1P2 C1A4 was silent, which is the one command in the
exchange that starts the PACE ECDH setup and so the only one that ever
asks for more time. Older passports read because they ask for a smaller
multiplier, where the wrong formula still produces a usable number.

Tested on RDV4 against that document: the MSE:Set AT that returned nothing
now answers 9000, and hf emrtd dump completes in 3 seconds with PACE
(ECDH, Generic Mapping, 3DES-CBC-CBC, NIST P-256), every data group read
and every EF_SOD hash matching.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-01 11:34:40 -04:00
didierA d987c3aab8 fixes compile fail on aarch64 (issue #3394) 2026-09-01 17:27:42 +02:00
iceman1001 12a890f444 text 2026-09-01 16:24:46 +02:00
iceman1001 89b1de6526 user supplied keys was not taken in consideration and also it left the field on 2026-09-01 16:17:35 +02:00
YoungJules 6bc39ff78c Fix pm3line fallback for ProxSpace/MinGW builds 2026-09-01 14:20:12 +02:00
Philippe Teuwen 18aed4eaa4 spurious hidden char 2026-09-01 14:09:49 +02:00
Philippe Teuwen 3ed5792b23 fix doc link 2026-09-01 14:07:12 +02:00
iceman1001 81a6f3bf3d style 2026-09-01 13:34:23 +02:00
iceman1001 be88db1b54 move clock 2026-09-01 13:34:02 +02:00
iceman1001 b65017ceaf move clocks 2026-09-01 13:32:49 +02:00
iceman1001 2fc7f81a4a fix PM3_GENERIC builds. dont compile SAM-sim module things 2026-09-01 13:30:04 +02:00
iceman1001 2f8f72b679 text 2026-09-01 13:06:08 +02:00
iceman1001 b2fa9d540e usart: drop the rx ring, read straight from the PDC banks
Saves 1040 bytes of .bss (BigBuf on AT91), removes a second copy of every
byte, and fixes a full/empty ambiguity where filling the ring to exactly
sizeof(us_rxfifo) left low == high, so usart_rxdata_available() returned 0
and the next bank overwrote 1 kB of received data.
2026-09-01 13:01:44 +02:00
iceman1001 f4bfda2b3c fix overzealous check for data_availablitity in 'hf 15/iclass' commands 2026-09-01 12:59:50 +02:00
iceman1001 db7686d988 forgot to empty the trace when clearing bigbuf 2026-09-01 12:55:38 +02:00
iceman1001 96ed916074 recompress fpga streams 2026-09-01 11:34:45 +02:00
iceman1001 83c3f81b1b move to 16kb fpga ring buffer size, recompile fullimage and lower stack size to 7160 bytes 2026-09-01 10:14:35 +02:00
Iceman ea5b017299 Merge pull request #3568 from innocentbystanderproxmark/master
Consolidiating/Cleaning up PM5 First Time Use documentation
2026-09-01 15:08:45 +07:00
Iceman 6c5be68fe7 Merge pull request #3565 from pkilar/epassport-diagnose-failed-reads
Fix ePassport reporting of failed reads, and decode EF_CardAccess
2026-09-01 15:08:15 +07:00
iceman1001 7326003be3 lessen stack usage 2026-09-01 06:41:00 +02:00
iceman1001 453c192a32 lessen stack usage 2026-09-01 06:40:46 +02:00
iceman1001 ef2ffa2bb4 lessen stack usage 2026-09-01 06:40:26 +02:00
iceman1001 70b2262326 lessen stack usage 2026-09-01 06:40:07 +02:00
iceman1001 f1cc02a6ca lessen stack usage 2026-09-01 06:39:04 +02:00
iceman1001 03f9601cc2 lessen stack usage 2026-09-01 06:38:29 +02:00
DJ Eric James bc7f0716a1 fixes 2026-08-31 23:42:38 -04:00
DJ Eric James aa189ca70c move files a bit. 2026-08-31 23:40:48 -04:00
DJ Eric James 1b4ac29a1e move files a bit. 2026-08-31 23:40:24 -04:00
DJ Eric James bfb7307216 fixes 2026-08-31 23:37:13 -04:00
DJ Eric James 7510e4faa5 fixes 2026-08-31 23:35:52 -04:00
DJ Eric James c5a67dad5f fixes 2026-08-31 23:32:59 -04:00
DJ Eric James c7915c5b83 fixes 2026-08-31 23:30:54 -04:00
DJ Eric James ab4ec63efd fixes 2026-08-31 23:29:08 -04:00
DJ Eric James 27dcb6a63c fixes 2026-08-31 23:25:55 -04:00
DJ Eric James cdf4a097bc fixes 2026-08-31 23:25:03 -04:00
DJ Eric James 4c454f387b fixes 2026-08-31 23:24:06 -04:00
DJ Eric James 50ee709954 fixes 2026-08-31 23:22:52 -04:00
DJ Eric James 7899b560a1 fixes 2026-08-31 23:19:59 -04:00
DJ Eric James b1de4b52c1 fixes 2026-08-31 23:19:03 -04:00
DJ Eric James bf230b4db4 fixes 2026-08-31 23:18:00 -04:00
DJ Eric James 6b12579546 fixes 2026-08-31 23:15:39 -04:00
DJ Eric James 52686ab6d2 fixes 2026-08-31 23:14:39 -04:00
DJ Eric James 5649bb268d fixes 2026-08-31 23:13:57 -04:00
DJ Eric James 399afc31a2 fixes 2026-08-31 20:40:58 -04:00
DJ Eric James b80be3cbf8 restructure document 2026-08-31 20:14:52 -04:00
DJ Eric James 243f1a0861 docu2 2026-08-31 19:09:36 -04:00
DJ Eric James f67eb452e3 docu2 2026-08-31 19:01:03 -04:00
DJ Eric James 703c7129fa docu2 2026-08-31 18:34:29 -04:00
DJ Eric James 448daf96b9 docu2 2026-08-31 18:33:55 -04:00