I’m testing an application that interfaces with a card reader and reads information from a smart card. I want to virtualize the testing by getting the application to recognize a virtual smart card through a virtual smart card reader and to invoke the card to respond with a random number every time I “plug-in” the smartcard. The idea is to “plug-in” the card in a loop to simulate appx. 1000 card reads and each time the card has to provide a random number. Furthermore, the application is listening on a COM port and since the Bix Virtual Card reader opens up ports 35963 and 35964 then I’m also rerouting the traffic from TCP ports to COM ports.
Please let me know If I’m overcomplicating things, but basically I need to get the application to pick up a different smart card on a com port in a loop for about 1000 reads.
Here’s what I’ve done so far:
Downloaded the Bix Virtual Card Reader: https://github.com/frankmorgner/vsmartcard/issues/101
Downloaded the Virtual Smart Card: https://github.com/frankmorgner/vsmartcard/releases/download/virtualsmartcard-0.7/virtualsmartcard-0.7_win32.zip
Launched the Python script (vicc.py) and according to the following forum post, the card and card reader are functioning properly: https://github.com/frankmorgner/vsmartcard/issues/82.
The Device manager recognizes both the Smart Card Reader and the card.
Diagnostic Tools Used:
I’m using Gemalto PC/SC IDBridge (http://support.gemalto.com/index.php?id=download_tools) to interact with the card but I don’t know which command I should send to the card to invoke the generation of a random number.
I’m using Fabulatech’s serial port redirector to create a connection between the TCP port and a virtual COM port https://www.fabulatech.com/serial-port-redirector.html
NOTE: The connection (in Virtual COM2) is established after I run the following commands in Gemalto:
- 1GemSafeSelectDF
- 2GetResponse
- 3GemSafeSelectEF
- 4GetResponse
- 5VerifyPinGemXplore
- 6ModifyPinGemXplore
- 7GemSafeVerifyPin
- 8ExtendedAPDUWrite10
P.S. I’m also using ScriptCommnicator (https://sourceforge.net/projects/scriptcommunicator/?source=typ_redirect) to listen to traffic on com port 2 (just for confirmation), but I don’t think I have it set-up correctly because I’m picking up gibberish: ÿÿmÿ