Mifare DesFire Authentication

Forum / MIFARE and NFC Reader IC`s / Mifare DesFire Authentication

  • 14. July 2016 at 17:56

    I registered to your docstore.nxp.com

    I have permission to Mifare Desfire EV1 but this datasheet doesnt contain chapter 4.1 with 3 mutual pass authentication example about you wrote in the 6th post.

    Can you send me where i can find datasheet :MIFARE DESFire EV1, Functionality of implementations on smart card controllers
    with chapter 4.1 example values


    + 0  |  - 0

    Re: Mifare DesFire Authentication

    5. August 2016 at 13:43
    Hello all, I want to ask about Mifare Desfire authentication.
    I did DES authentication and the result is 0x00 or OK but with the same method and flow, I did AES authentication and the result is 0xAE or authentication error. What I read before, my problem is IV for encryption. The initial IV is 0x00 (16 bytes) and I am not sure about the second IV.
    I have tried last 8 bytes of e(RndB) and followed by 0, whole e(RndB) as IV at second encryption but the result still 0xAE. Is there something I miss about the AES authentication?
    Thank you for the answer.

    Best Regards,
    Richard Kartiyanta
    + 0  |  - 0

    Re: Mifare DesFire Authentication

    9. February 2022 at 8:19

    I need your help. I have to AES authenticate my DESFire EV1 4K card. Can you tell me should I use the same IV along the three-pass authentication or is it calculated in each step? The problem is in the last step. Decrypted RndA' from the card is not the same as my RndA'. Here are the steps I use:

    1. Receive encrypted RndB from the card.
    2. Decrypt encrypted RndB (IV - 16 bytes of zeros).
    3. Rotate RndB one byte to the left (RndB')
    4. Generate RndA
    5. Concatenate RndA and RndB'
    6. Encrypt concatenated value (IV - still 16 bytes of zeros)
    7. The card responds successfully and gives me encrypted RndA'
    8. Decrypt encrypted RndA' (IV - still 16 bytes of zeros)
    9. Rotate my RndA one byte to the left (RndA')
    10. Decrypted RndA' is not equal to my RndA'

    Thank you in advance.

    Kind regards,
    + 0  |  - 0
Viewing 3 posts - 16 through 18 (of 18 total)

You must be logged in to reply to this topic.