From 571ac282297954f945412740404a7a70912db31f Mon Sep 17 00:00:00 2001 From: Philippe Teuwen Date: Sun, 15 Dec 2024 14:02:52 +0100 Subject: [PATCH] st25ta02kb getsignature: handle locked tags --- client/src/cmdhfst25ta.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/client/src/cmdhfst25ta.c b/client/src/cmdhfst25ta.c index fcf5791d0..9656d8146 100644 --- a/client/src/cmdhfst25ta.c +++ b/client/src/cmdhfst25ta.c @@ -183,7 +183,13 @@ static int st25ta_get_signature(uint8_t *signature) { } activate_field = false; } - + if (resplen != 32) { + if ((resplen == 2) && (resp[0] == 0x69) && (resp[1] == 0x82)) { + PrintAndLogEx(WARNING, "GetSignature: Security status not satisfied"); + } + DropField(); + return PM3_ESOFT; + } if (signature) { memcpy(signature, resp, 32); }