1

In a Windows 8 Store App I would like to read Data from a SmartCard. After installing the SmartCard reader (USB Device) I can read its device path and connection state via the Windows.Devices.Enumeration namespace. Even the device interface id is retrievable (50dd5230-ba8a-11d1-bf5d-0000f805f530) and I put this as a required capability in the App's manifest file.

For the interaction with the device I use a C++ Component calling the CreateDeviceAccessInstance Method. But this call always results in an ACCESS_DENIED exception.

Further research taught me, that interacting with a custom hardware device (everything that is not a printer, microphone, mouse, ...) would need several adjustments in the device driver published to the windows 8 driver store. I'd be glad to do so, but I am no IHV and would like to use the generic driver and the generic interface.

Could anyone give me a hint how to proceed from here and use the generic interface for USB SmartCard devices?

Nico
  • 2,120
  • 16
  • 20

1 Answers1

0

This is not a real answer, but I have the same problem and I have spent quite some time looking for the hard-to-find bits of information on this subject around the internet, and I'd like to share my results.

Windows 8.1 has some specific APIs for (virtual) SmartCards (API reference, sample), but it seems like they can only be used for authentication and there is no way to send APDU commands to a card at the moment (see this comment by Himanshu Soni). I guess one could use the new USB APIs to talk to the reader directly, but then you'd have to implement the whole protocol yourself.

Daniel Sklenitzka
  • 2,116
  • 1
  • 17
  • 25
  • Thanks for getting back to this issue even after such a long time :) As Himanshu Soni states in his comment, I am currently using a desktop service that communicates with the smartcard reader and hand the data to the StoreApp resulting in the need of SideLoading capabilities and the lack of supporting Surface devices... But those new USB Apis sound interesting. I'll have a look at them and come back here soon... Nico – Nico Jul 08 '13 at 13:04
  • Whew, what a 17 item ToDo-list that starts with writing a custom Driver on item#1 (http://msdn.microsoft.com/en-us/library/windows/apps/dn312121.aspx). I think I managed to get that generic WinUSB Driver running for a SmartCardReader device but still fail at retrieving the UsbDevice object (item#8). Have you successfully accessed a smart Card device yet? – Nico Jul 09 '13 at 08:58
  • 1
    Thanks for the update! No, we haven't tried that yet. For our purpose, a desktop service might talking to the reader might be enough, although of course it would be nice if it worked directly. We'll talk to the manufacturer of our reader. I'll keep you posted. ;) If you want, we can also stay in contact directly by email (and in german): vorname.nachname@softaware.at – Daniel Sklenitzka Jul 10 '13 at 06:03