I earlier asked some questions here regarding Mifare RFID cards, i successfully read the hex value of the cardds unique ID.
Now I got a few other cards I am having some issues with, my reader reacts to them, and HID omnikey reader does read this ID number from the workbench application, i sent earlier the following hex sequences: FF CA 00 00 00 which allowed me to read this from standard mifare cards, however with the Desfire this seem not to work for me,
anyone with any smart input here?
If I understand your question, you are asking what is the APDU sequence to send to a Mifare DESFire card to get the unique ID (UID).
This blog post may help you.
There is a command called GetVersion() that will return successively several interesting information. That command has the hexadecimal code 0x60. You have two ways to send it :
either
--> 60
<-- AF 04010101001805
or
--> 9060000000
<-- 04010101001805 91AF
The answer received is an example. It's information about the hardware, the AF (at beginning or end of answer) means that the card can provide more information. The other information from that answer are not relevant for the UID but are described in the blog post indicated before.
To get more info, send either
--> AF
<-- AF 04010101041805
or
--> 90AF000000
<-- 04010101041805 91AF
You receive a new answer from the card which are not relevant to get the UID (it's software information) but are described in the blog post. A new AF indicate there is more information available.
You send either
--> AF
<-- 00 048A4AAAA62D80BA34D5E9103612
or
--> 90AF000000
<-- 048A4AAAA62D80BA34D5E9103612 9100
You will finally receive an answer with the UID. The first 7th bytes are your UID. In my example it's : 04 8A 4A AA A6 2D 80.