CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 6 of 6
  1. #1
    Join Date
    Dec 2008
    Posts
    16

    Virtual SmartCard Reader driver development

    Hello
    I'm writing a virtual SmartCard Reader driver for WinXP, the goal is
    to pass APDU's through two interfaces : PC/SC <-> SerialPort(COM)

    I've read a lot before posting, but i got all confused:

    Firstly, a little confused about writing in WDM or WDF and the type of
    driver (Function or Filter driver), in the end i chose writing in WDF
    (KMDF) and a Function Driver, correct me if i got it wrong.

    Secondly, from the WDK documentation/books i understood that i need to
    write some kind of DEVICE_EXTENSION structure that is needed for WDF
    Framework, AND some kind READER_EXTENSION structure that is used by
    SMARTCARD_EXTENSION (typically for the SmartCard driver).
    Problem is that i don't know how to write these.. didn't find any
    rules and i don't know what is needed for everything to work.

    Thirdly, my driver shows in Device Manager list but DOES NOT show in
    available readers list in the applications, i've read that the driver
    must register with "smclib" but i don't know what lines I need to
    write to make it happen. (How to make the reader visible in the
    applications that support PS/SC readers?)

    Example code in WDK dosen't help any more, so i came here.
    Any kind of help is welcome, thanks in advance
    I'm a newbie on writing drivers and this is my first post, so please forgive any inconvenience and mistakes.
    Lucas.

  2. #2
    Join Date
    Feb 2009
    Posts
    1

    Re: Virtual SmartCard Reader driver development

    hi... just wondering whether u found answers for your Qs.. coz im also starting a similar project..

  3. #3
    Join Date
    Dec 2008
    Posts
    16

    Re: Virtual SmartCard Reader driver development

    Yes, project is possible to do, KMDF is great option to do it. Second question requires reading some basic Driver Development books and WDK Help, Third requires really really REALLY good study of one example included in WDK.
    Im preety stuck at my other post, but no answers suggest anoter more and more studying of that example.

  4. #4
    Join Date
    Feb 2009
    Posts
    1

    Re: Virtual SmartCard Reader driver development

    Hi hash3d,

    Can you explain your project in more detail? What do you mean by defining "virtual" smartcard reader? Don't you have the physical reader? or what?

    And by "virtual" reader, do you need a "virtual" smartcard too? Can you share some information about your driver stack?

  5. #5
    Join Date
    Dec 2008
    Posts
    16

    Re: Virtual SmartCard Reader driver development

    Well generally the idea was to make a connection between PC/SC interface and Serial interface on the kernel side with a possibility to choose what serial driver (COM port) the PC/SC interface is connected to.

    There is some hardware, but it can be easily replaced by software on kernel level or user level, but the driver also works fine without any I call it a "virtual" one.

    For normal user the driver is a standard SCReader driver, the stack isn't changed at all.

  6. #6
    Join Date
    Jul 2014
    Posts
    1

    Re: Virtual SmartCard Reader driver development

    hello,

    I want to develop a virtual smart card reader too, I've read your post. I didn't know I should implement a legacy device driver or a wdf type? I want a a virtual smart card reader that can insert, remove, do power operations and give back ATR sting? I don't know how system find my driver and use it? Could you explain about this questions? Could you please upload the source code of your driver? or send it to me? Thanks for advance.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured