From 7a30e354966ac1f6a8e68e43d2585f99dd0e03ea Mon Sep 17 00:00:00 2001 From: Philippe Teuwen Date: Tue, 28 Jan 2014 00:22:33 +0100 Subject: [PATCH] nfc-mfclassic: update help & man page --- utils/nfc-mfclassic.1 | 22 ++++++++++++++++++---- utils/nfc-mfclassic.c | 2 +- 2 files changed, 19 insertions(+), 5 deletions(-) diff --git a/utils/nfc-mfclassic.1 b/utils/nfc-mfclassic.1 index d1f9117..bfef5e3 100644 --- a/utils/nfc-mfclassic.1 +++ b/utils/nfc-mfclassic.1 @@ -3,10 +3,13 @@ nfc-mfclassic \- MIFARE Classic command line tool .SH SYNOPSIS .B nfc-mfclassic -.RI \fR\fBr\fR|\fR\fBR\fR|\fBw\fR\fR|\fBW\fR +.RI \fR\fBf\fR|\fR\fBr\fR|\fR\fBR\fR|\fBw\fR\fR|\fBW\fR .RI \fR\fBa\fR|\fR\fBA\fR|\fBb\fR\fR|\fBB\fR .IR DUMP -.IR [KEYS] +.RI [ +.IR KEYS +.RI [\fR\fBf\fR] +.RI ] .SH DESCRIPTION .B nfc-mfclassic @@ -27,6 +30,10 @@ to store the keys and data for all sectors. Be cautious that some parts of a MIFARE Classic memory are used for r/w access of the rest of the memory, so please read the tag documentation before experimenting too much! +The +.B f +option to format the card will reset all keys to FFFFFFFFFFFF, all data to 00 and all ACLs to default. + The .B W option allows writing of special MIFARE cards that can be 'unlocked' to allow block 0 @@ -57,8 +64,10 @@ options only work on special versions of MIFARE 1K cards (Chinese clones). .SH OPTIONS .TP -.BR r " | " R " | " w " | " W -Perform read from ( +.BR f " | " r " | " R " | " w " | " W +Perform format ( +.B f +) or read from ( .B r ) or unlocked read from ( .B R @@ -86,6 +95,11 @@ MiFare Dump (MFD) used to write (card to MFD) or (MFD to card) .TP .IR KEYS MiFare Dump (MFD) that contains the keys (optional). Data part of the dump is ignored. +.TP +.B f +Force using the keyfile +.IR KEYS +even if UID does not match (optional). .SH BUGS Please report any bugs on the diff --git a/utils/nfc-mfclassic.c b/utils/nfc-mfclassic.c index c206fc3..1242886 100644 --- a/utils/nfc-mfclassic.c +++ b/utils/nfc-mfclassic.c @@ -476,7 +476,7 @@ static void print_usage(const char *pcProgramName) { printf("Usage: "); - printf("%s r|R|w|W a|b [ [f]]\n", pcProgramName); + printf("%s f|r|R|w|W a|b [ [f]]\n", pcProgramName); printf(" f|r|R|w|W - Perform format (f) or read from (r) or unlocked read from (R) or write to (w) or unlocked write to (W) card\n"); printf(" *** format will reset all keys to FFFFFFFFFFFF and all data to 00 and all ACLs to default\n"); printf(" *** unlocked read does not require authentication and will reveal A and B keys\n");