YstokCard - smart card API
The project is hosted at http://lisp.ystok.ru/ycard/" YstokCard is a portable Common Lisp library dealing with smart cards.
It allows a Lisp program to interact to integrated chip cards (ICC) and interface devices (IFD, card readers).
Memory cards can securely store relatively small amounts of data. Applications usually require certain conditions to be fulfilled before access to the data is possible, such as a PIN verification or authentication of the card.
Processor cards provide environment for the secure execution of programs. This makes smart cards good candidates for the entire security sector. Additionally, they have a well-established format and are convenient for manual use and handling.
YstokCard can be useful for programming both memory-based and file-based card applications. "
Basic features
- Class hierarchy for cards and devices.
- Conventions and macros for defining new card and device types.
- ATR (Answer-To-Request) converting and analysis.
- Calls to Smart Card Resource Manager (
winscard.dll
on Windows,libpcsclite.so
on Linux). - Helpers like run-length-coding (RLC) etc.
Installation
I tried to install the wrapper on my Debian system with some documentation from the wrapper author himself: Dmitry Ivanov.I failed to install the wrapper :-(. I am no more a Lisp user and I did not want to invest too much time in setting a working configuration.
Here is the documentation I got from Dmitry Ivanov in case you want to try by yourself:
The wrapper will not work with CLISP but only with:
- LispWorks (http://www.lispworks.com/)
most popular commercial implementation,- SBCL (http://sbcl.org/)
most popular open source implementation, which is available on Debian.
Build/install means compile and load into a running Lisp system. The
procedure is not a simple "apt-get" call but consists of the manual
operations.
- Download zip/tgz bundles for all the dependencies.
- Extract all the files.
- Load ASDF package manager into the running lisp image by means of
- either (if included into the Lisp distribution) calling
(provide "asdf")
- or downloading from http://common-lisp.net/project/asdf/ and calling
(load "asdf.lisp")
- Load all the unzipped ASD-files, i.e. project files, e.g.
(load "ystok-ffc.asd")
(load "ystok-library.asd")
(load "ystokcard.asd")
- Evaluate
(asdf:operate 'asdf:load-op 'ystokcard)
.
Source code
Since I failed to install the Common Lisp wrapper I could not really write the sample code and test it.Writing the sample source code is then left as an exercise to the reader :-)
Conclusion
I am sorry I can't really help you on this Common Lisp PC/SC wrapper.If you are a Common Lisp user I imagine you will succeed in installing the wrapper correctly and using it for your project.
Even if I failed to install it myself I wanted to let you know that a Common Lisp wrapper exist for PC/SC.