Home arrow C++ arrow Writing a Smart Card Library

Writing a Smart Card Library

In this article we are going to develop a Smart Card Library that will ease the development of Smart Card Applications using the Win32 SDK and/or MFC. This assumes that youíre familiar with Win32 and MFC. The library builds upon the available support for Smart Cards in Windows by providing an Object Oriented wrapper over the WinSCard API. One advantage of using this library is the layered approach, which isolates the core APIís available to non-Win32 conformant languages like java to access this library through JNI (Java Native Interfaces). If youíve already developed some applications using the APIs exposed by WinSCard.dll then youíll be well aware of the complexities involved and here is an attempt to ease them.

Author Info:
By: Digvijay Chauhan
Rating: 5 stars5 stars5 stars5 stars5 stars / 116
April 26, 2004
  1. · Writing a Smart Card Library
  2. · The Approach
  3. · The CPCSCReader Class
  4. · The CRegListDlg Class
  5. · The Demo Application: SCardDemo

print this article

Writing a Smart Card Library
(Page 1 of 5 )

  Before you begin, go ahead and download the support file.

Microsoft has provided several enhancements toward the use of PCSC conformant Smart Cards with the operating systems releases made after Windows 2000.There is available a COM wrapper and Smart Card Base Components provided as a part of this enhancements.

The heart of this Subsystem is the WinSCard.dll which exposes raw APIs for managing and accessing PCSC compliant Smart Card readers. In order to take a quick look at what it exposes, you can just use the Dependency Walker. Below is a Snapshot of the same.

Writing a Smart Card Reader
Figure 1: The API exports by WinSCard.dll

There are around 60 exports from this DLL and cover most parts of the PCSC specification. Here we would try encapsulating some of the core APIs to develop an object-oriented wrapper that we can use to develop MFC applications that use Smart Cards.

blog comments powered by Disqus

- Intel Threading Building Blocks
- Threading Building Blocks with C++
- Video Memory Programming in Text Mode
- More Tricks to Gain Speed in Programming Con...
- Easy and Efficient Programming for Contests
- Preparing For Programming Contests
- Programming Contests: Why Bother?
- Polymorphism in C++
- Overview of Virtual Functions
- Inheritance in C++
- Extending the Basic Streams in C++
- Using Stringstreams in C++
- Custom Stream Manipulation in C++
- General Stream Manipulation in C++
- Serialize Your Class into Streams in C++

Watch our Tech Videos 
Dev Articles Forums 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us 
Weekly Newsletter
Developer Updates  
Free Website Content 
Contact Us 
Site Map 
Privacy Policy 

Developer Shed Affiliates


© 2003-2018 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap
Popular Web Development Topics
All Web Development Tutorials