From: Arnie97 Date: Thu, 1 Feb 2018 07:09:14 +0000 (+0800) Subject: hf mf nested: use bitwise or instead. (#556) X-Git-Tag: v3.1.0~77 X-Git-Url: http://cvs.zerfleddert.de/cgi-bin/gitweb.cgi/proxmark3-svn/commitdiff_plain/32e6891a05f70ebdfae44671c9e5fde3035bb598 hf mf nested: use bitwise or instead. (#556) --- diff --git a/client/cmdhfmf.c b/client/cmdhfmf.c index dbb6d092..f5d7a5be 100644 --- a/client/cmdhfmf.c +++ b/client/cmdhfmf.c @@ -683,9 +683,9 @@ int CmdHF14AMfNested(const char *Cmd) if (transferToEml) { uint8_t sectortrailer; if (trgBlockNo < 32*4) { // 4 block sector - sectortrailer = (trgBlockNo & ~0x03) + 3; + sectortrailer = trgBlockNo | 0x03; } else { // 16 block sector - sectortrailer = (trgBlockNo & ~0x0f) + 15; + sectortrailer = trgBlockNo | 0x0f; } mfEmlGetMem(keyBlock, sectortrailer, 1);