fix: crapto3.3 sometimes crashing with hf mf mifare on Fudan clones (no par, all NACK) (#233)

added readme.txt again in tools/nonce2key
This commit is contained in:
pwpiwi 2017-03-20 21:05:26 +01:00 committed by GitHub
commit de867f502f
6 changed files with 16 additions and 18 deletions

View file

@ -14,7 +14,7 @@ all: $(OBJS) $(EXES)
%.o : %.c
$(CC) $(CFLAGS) -c -o $@ $<
% : %.c
% : %.c $(OBJS)
$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(OBJS) $<
clean:

View file

@ -47,7 +47,7 @@ int main(const int argc, const char* argv[]) {
printf("%01x|\n",par[i][7]);
}
state = lfsr_common_prefix(nr,rr,ks3x,par);
state = lfsr_common_prefix(nr,rr,ks3x,par,0);
lfsr_rollback_word(state,uid^nt,0);
crypto1_get_lfsr(state,&key_recovered);
printf("\nkey recovered: %012" PRIx64 "\n\n",key_recovered);

View file

@ -0,0 +1,7 @@
To test the nonce2key tool.
:: tip
You can use the output from "hf mf mifare" to use with this tool.
:: sample
./nonce2key e9cadd9c a8bf4a12 a020a8285858b090 050f010607060e07