Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

SCARD_E_UNKNOWN_READER

436 views
Skip to first unread message

Alfredo

unread,
Oct 7, 2004, 1:21:58 PM10/7/04
to
Issue: I get a "SCARD_E_UNKNOWN_READER" error message when trying to
communicate to a cryptoflex smart card card. The error occurs when calling
"SCardConnect"

Code Snippet:
-------------------------------------------------
SCARDCONTEXT hContext;
char *ReaderBrand = "SchlumbergerSema e-gate 0";
SCARDHANDLE hCard;
DWORD dwActiveProtocol;

/*SCardEstablishContext -> returns SCARD_S_SUCCESS*/
hResult = SCardEstablishContext(SCARD_SCOPE_SYSTEM, NULL, NULL, &hContext);

/*SCardConnect returns -> SCARD_E_UNKNOWN_READER on the test machine */
hResult = SCardConnect(hContext, ReaderBrand, SCARD_SHARE_SHARED,
SCARD_PROTOCOL_T0, &hCard, &dwActiveProtocol);
---------------------------------------------------

Note:

1. The application works great on my development machine however the error
occurs when trying to use the PCSC smart card application on a test machine
that does not have visual studio installed.

2. I'm able to communicate to the card on the test machine via "Schlumberger
Smart Card toolkit" that was installed.


Additional Information:
Development env: VC++ 6.0 (development machine)
Schlumberger development env: SDK 4.4 (both machines)
Smart Card: Cryptoflex egate 32k (both machines)
OS: Windows 2k (both machines)
C:\WINNT\system32\winscard.dll version: 5.0.2134.1 (both machines)


I have also tried to resolve the issue by copying the
"HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Cryptography\" Registry hive to the
test machine from the development machine.

-------------------------------------------------------
Reg hive snippet:
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Cryptography\Calais\Readers\SchlumbergerSema e-gate 0]
"Device"="SchlumbergerSema e-gate 0"
"Groups"=hex(7):53,00,43,00,61,00,72,00,64,00,24,00,44,00,65,00,66,00,61,00,75,\
00,6c,00,74,00,52,00,65,00,61,00,64,00,65,00,72,00,73,00,00,00,00,00

--------------------------------------------------------

I also installed the latest e-gate_W2k_XP_24 drivers both machines machine.'


Any suggestions, common causes, or additional information on what might
cause the error would be greatly appreciated.

Alfredo


Alfredo

unread,
Oct 12, 2004, 5:25:05 PM10/12/04
to
Just in case any one is interested.

Cause of the issue:
It appears that the original Schlumberger SDK installed on the development
machine configured the reader identified as "SchlumbergerSema e-gate 0" in
the registry. The new driver update configures it as "Schlumberger e-gate 0".

0 new messages