PC/SC and CCID PC/SC Reader
Standard CCID Smart Floppy Plug-in Card Reader
DualKey Contactless Card and SIM Smart Keyboard PCMCIA Sized Contact Card Reader Prior to PC/SC
No standardization on reader communication protocols No standardization on application APIs Application locked to vendor-specific drivers & readers Expensive readers, few smart card applications PC/SC Smart Card Readers
Workgroup formed in 1996 Microsoft, with major card and computer vendors as founding members Addresses need for PC – Smart Card Reader interoperability Can have multiple readers and different interfaces (eg. PCMCIA, RS232, USB, etc.) Applications and vendors are neutral . Defines how a smart card reader interfaces to the OS & how an application interfaces with the OS to interact with the smart card reader and smart card . The application is not locked to any vendor’s reader Does not define the smart card reader communication protocol . Reader’s vendor must supply the PC/SC driver PC/SC
ICC - Aware Application ICCICC- Aware- Aware Application Application PC/SC Service Provider Reference Interfaces Service Service ProvidersService Providers Provider PC/SC RM Interface MicrosoftResource Resource Manager Manager PC/SC IFD Handler Interface IFDIFD IFDIFD IFDIFD Drivers HandlerHandler HandlerHandler HandlerHandler
IFDIFD IFDIFD IFDIFD Smart Card Readers
ICC ICC ICC Smart Cards CCID
The CCID Protocol is defined by the USB consortium. The CCID driver is available from: . Microsoft for Win 2K, XP and Win Server 2003 . Linux, Mac The CCID PC/SC driver is built into Windows Vista onwards. PC/SC API
SCardEstablishContext SCardIntroduceCardType() GetOpenCardName() / SCardStatus() SCardUIDlgSelectCard() SCardTransmit() SCardConnect() SCardReconnect() SCardListCards() SCardLocateCards() SCardListReaders() SCardReleaseContext SCardGetStatusChange() SCardDisconnect() This is the content of ConsoleApp.cpp
ReturnCode = connectToCard(DlgStruct->hSCardContext, DlgStruct->lpstrRdr, SCARD_SHARE_SHARED, SCARD_PROTOCOL_T0, &(DlgStruct->hCardHandle), &(DlgStruct->dwActiveProtocol)); if(ReturCode != SCARD_S_SUCCESS) printf("Failed connection to the card0X%0X.\n",ReturnCode);
Questions?