Reply To: How to encrypt Sector 1 Data Values?

Forum MIFARE SDK How to encrypt Sector 1 Data Values? Reply To: How to encrypt Sector 1 Data Values?

Re: How to encrypt Sector 1 Data Values?

16. May 2016 at 20:19
Hi,

Each block Mifare Classic 1KB, has 16 bytes long (128 bits), so that it is possible to use any method for convenience 128 bit encryption.

Among the most used you could do with 3DES or AES, but I would be inclined to use AES. These algorithms allow use as Data multiples of 16 bytes in length and the key should be 16 bytes in length.

You should only be used as Data encryption block of 16 bytes and should preferably use a key that is diversified by the uid and block number. This will see different cards in different data for the same message.

With this you could encrypt each block separately or a better option might be you encrypt the 3 blocks with AES, but in CBC mode where encryption is chained.

I hope to help you with what you request.
+ 0  |  - 0