I am unable to change the sector key in MIFARE classic 1k, it only takes default key FF FF FF FF FF FF.... how i can do that ???

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

I am unable to change the sector key in MIFARE classic 1k, it only takes default key FF FF FF FF FF FF.... how i can do that ???

3,351 Views
ankitjohri
Contributor I

Dear Team,

Please help to resolve this problem:

I am using ACR122U reader with mifare classic 1k card and sample code in c#(attached is the screenshot and commands which i have run).

First i authenticate sector-6(blockno.23 ) with by default load key 01 which is FF FF FF FF FF FF which load in Key 01..... so authentication done successful as

< FF 86 00 00 05 01 00 17 60 01

> 90 00
Authentication success!

After that i tried to write something in block 20 of sector 6 as text "My name is lakha" which gives this

< FF D6 00 14 10 6D 79 20 6E 61 6D 65 20 69 73 20 6C 61 6B 68 61

> 90 00

After that i load key again 01 as A5 A4 A3 A2 A1 A0 it gives me this 

< FF 82 00 01 06 A5 A4 A3 A2 A1 A0
> 90 00

then when again i tried to authenticate sector 6 block 23 with this new key A5 A4 A3 A2 A1 A0 under Key 01  it gives me error like as below;

< FF 86 00 00 05 01 00 17 60 01
> 63 00
Authentication failed!
< FF 86 00 00 05 01 00 17 61 01
> 63 00
Authentication failed!

Please let me know why i am unable to do block or sector authentication after new key change.

mifare classic authentication  Polling/Read/Write Mifare-Defire ?

0 Kudos
1 Reply

2,047 Views
Kan_Li
NXP TechSupport
NXP TechSupport

Hi ANKIT,

How do you know A5 A4 A3 A2 A1 A0 is a valid key?


Have a great day,
Kan

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos