简体   繁体   中英

Reading Mifare Classic & Desfire cards via Omnikey 5022 reader

I have an Android project for which I need to read 3 types of NFC cards namely Mifare Ultralight, Mifare Classic, and Desfire Cards via an Omnikey 5022 reader connected to the app through USB.

I did some digging and was successfully able to read the Mifare Ultralight cards. The command I used for reading a specific page on the ultralight card was "FFB000 01 10" for page 1, where I was able to change the highlighted number to read whatever page was required.

I am looking for similar commands to read Mifare classic and Desfire cards(certain blocks/application).

For Mifare classic , we need to authenticate the sector 5 with key A and the default key "FFFFFFFFFFFF". Similarly for Desfire cards I need to read the 0th application.

Can someone help me or point me in the right direction for these?

Also even if I figure out commands to read data off of all 3 cards, can someone help me how can I distinguish between them and thus know which command to fire for which card. I have done this using the tag present in the intent when working with NFC reader present in the device, but not sure of how to do this with an external reader.

I have an Android project for which I need to read 3 types of NFC cards namely Mifare Ultralight, Mifare Classic, and Desfire Cards via an Omnikey 5022 reader connected to the app through USB.

I did some digging and was successfully able to read the Mifare Ultralight cards. The command I used for reading a specific page on the ultralight card was "FFB000 01 10" for page 1, where I was able to change the highlighted number to read whatever page was required.

I am looking for similar commands to read Mifare classic and Desfire cards(certain blocks/application).

For Mifare classic , we need to authenticate the sector 5 with key A and the default key "FFFFFFFFFFFF". Similarly for Desfire cards I need to read the 0th application.

Can someone help me or point me in the right direction for these?

Also even if I figure out commands to read data off of all 3 cards, can someone help me how can I distinguish between them and thus know which command to fire for which card. I have done this using the tag present in the intent when working with NFC reader present in the device, but not sure of how to do this with an external reader.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM