What is the meaning of 6E 00 when I send a command to a SmartCard
Asked Answered
R

3

5

I try to access a SmartCard via C++. I got already the Connection and the CardHandle.

But when I send an APDU Command via SCardTransmit, i'll get 6E 00 as the answer from the card. No matter which APDU Command i send. Everytime 6E 00.

For Example:

  • FF CA FA 00 00 (Card's ATR - Answer To Reset) or
  • FF CA FF 82 00 (Product name in ASCII)

The same thing when i send the Command with an PC/SC Testtootl like "PC/SC Diag".

Has anybody an Idea what the meaning of this Error-Code and how to solve the problem?

Please help me !!!! ;-)

Ribaldry answered 7/7, 2011 at 10:48 Comment(1)
For anyone looking for other APDU responses, see this website for a great list!Conspire
S
7

According to ISO 7816-4 0x6E00 means "Class not supported".

Are you using the correct CLA value in the APDU?

The class (CLA) byte is usually 0x00, 0xA0, 0xC0 or 0xF0 and sometimes masked with 0x0C that indicates Secure Messaging on some cards. AFAIK, the only invalid CLA value is 0xFF.

But this varies from one card to another, do you have the card specification from the vendor?

Spurgeon answered 7/7, 2011 at 10:53 Comment(4)
Ah ok, when i use 0C or 00 i've got another Errorcode 6A 86. Where can i find a list of Errorcodes. I don't have the specification from the vendorRibaldry
You should read the ISO 7816-4 standard first before sending APDUs to the card.Fourscore
Ok thanks, i promise to read it. But i just want to get an answer from the card, so that i know every thing works fine. Can you tell me an easy apdu which i can send?Ribaldry
The easiest APDU command is probably the GET CHALLENGE which will ask the card for random data. CLA = card specific. INS = 0x84 P1 = 0x00 P2 = 0x00 LE = number of bytes you want (up to 0xFF for a short APDU).Fourscore
C
1

It means "Wrong Instruction Class". Maybe it's just the wrong type of card?

https://datatracker.ietf.org/doc/html/draft-urien-eap-smartcard-05

Curr answered 7/7, 2011 at 10:52 Comment(0)
B
0

The BasicCard PDF manual has a list of error codes on page 152-153.

The one you got they describe as "CLA byte of command not recognized".

"6A 86" is likely the response to a card specific command and I dont see it in the BasicCard list.

Bolduc answered 30/11, 2013 at 13:10 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.