Search code examples
windows-cesmartcardapdumifare

Mifare Standard 1K - 6D00 for external authentication APDU


External Authentication: FF 82 20 00 06 FF FF FF FF FF FF

What is the correct procedure to run External Authentication? Do we need to run Get Challenge before External Authentication?

If I send the apdu of external authentication to OMNIKEY smart card reader, it will return me 9000 which mean success.

But If I do the same step with Workabout Pro4 and it return 6D00?

6D00 is instruction code is not supported or invalid, but it was working with Omnikey smart card reader. How to solve this problem?

FYI: Read UID APDU Command is working on both devices: FF CA 00 00 00

I have tried many different ways but none is working.

  1. Changing the shared_mode while connect card[Exclusive, Shared]
  2. Lock the thread for specific process
  3. Put the thread to wait for few seconds before sending APDU
  4. Send Get Challenge apdu before external authentication but failed

Solution

  • I found the answer myself.

    There are two Load Authentication Keys APDU commands:

    1. FF 82 20 00 06 FF FF FF FF FF FF (Obsolete)
    2. FF 86 00 00 05 01 00 [Block Number] [Key Type] [Key Number]

    Use the second APDU command to do Load Authentication Keys then read/write the Mifare card content.