Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - Hardware
User Name
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?


  Search this Thread
Old 12-28-2008, 11:44 PM   #1
LQ Newbie
Registered: Nov 2008
Posts: 13

Rep: Reputation: 0
Using the GemPC USB-SW smartcard reader with Debian "etch" distro (Xandros OCE 4.5)


I am trying to get a smart card reader and my CAC card to work with a Debian "etch" based distro, Xandros 4.5 OCE. Here are results of lsusb and pcsc_scan:

xandroslaptop:~# lsusb
Bus 003 Device 005: ID 08e6:3437 Gemplus GemPC Twin SmartCard Reader
Bus 003 Device 004: ID 05e3:0604 Genesys Logic, Inc. USB 1.1 Hub
Bus 003 Device 001: ID 0000:0000
Bus 002 Device 001: ID 0000:0000
Bus 001 Device 001: ID 0000:0000

xandroslaptop:~# pcsc_scan
PC/SC device scanner
V 1.4.8 (c) 2001-2006, Ludovic Rousseau <>
Compiled with PC/SC lite version: 1.3.2
Scanning present readers
0: Gemplus GemPC Twin 00 00

Sun Dec 28 23:16:34 2008
Reader 0: Gemplus GemPC Twin 00 00
Card state: Card inserted,
ATR: (removed)

ATR: (removed)
+ TS = 3B --> Direct Convention
+ T0 = 6B, Y(1): 0110, K: 11 (historical bytes)
TB(1) = 00 --> VPP is not electrically connected
TC(1) = 00 --> Extra guard time: 0
+ Historical bytes: (removed)
Category indicator byte: 80 (compact TLV data object)
Tag: 6, len: 5 (pre-issuing data)
Data: B0 83 01 04 74
Tag: 8, len: 3 (status indicator)
LCS (life card cycle): 00 (No information given)
SW: 9000 (Normal processing.)

Possibly identified card (using /usr/share/pcsc/smartcard_list.txt):
Gemplus GXP3 64V2N
U.S. Department of Defense Common Access Card (DoD CAC)

I have the following packages installed on my system:

libccid 1.1.0-1
libopenct1 0.6.11-1
libopensc2 0.11.1-2etch2
mozilla-opensc 0.11.1-2etch2
libp11-0 0.2.2-2
libpcsclite1 1.3.2-5
libpcsc-perl 1.4.4-1
openct 0.6.11-1
opensc 0.11.1-2etch2
pcscd 1.3.2-
pcsc-tools 1.4.8-1
coolkey 1.1.0-7
(converted from a deb package by alien version 8.64)

It seems I have the correct drivers and pcscd restart works correctly and the pcsc_scan gives me a correct result. The problem is that when I am trying to add a new device module in Firefox, using the coolkey package and the module from that library, it says "unable to install module."

I am wondering if I should go with the driver and software from gemalto itself. Here is their readme:

"Readme for the Gemalto CCID Smart Card reader driver for the DEBIAN "Sarge".

Gemalto CCID Smart card reader drivers for Debian Sarge 3.1 Linux distribution
and x86 processor architecture.

Version 1.2.4, March 2006.

Before proceeding, you might want to check whether a new driver version
is available from


0. License
1. Description
2. Installation
3. Troubleshooting
4. Release notes
5. Support

0. License

All included programs are free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public License as
published by the Free Software Foundation; either version 2.1 of the License,
or (at your option) any later version.

All included programs are distributed in the hope that it will be
useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
General Lesser Public License for more details.

You should have received a copy of the GNU Lesser General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA

1. Description
This archive contains DEB packages of the CCID device driver for the Gemplus
CCID based devices and the PCSC-Lite daemon.

The CCID device driver:
* libccid_1.2.4-0_i386.deb

The pcsc-lite :

( from

* libpcsclite1_1.2.9-beta9-0bpo1_i386.deb
* libpcsclite-dev_1.2.9-beta9-0bpo1_i386.deb
* pcscd_1.2.9-beta9-0bpo1_i386.deb

This archive contains the source code of the CCID device driver for
the Gemplus CCID based devices and the PCSC-Lite daemon.

The CCID device driver:
* ccid-1.2.4.tar.gz

The pcsc-lite:
* pcsc-lite-1.2.9-beta10.tar.gz

It requires:
* A Debian Sarge 3.1 platform based on a x86 processor architecture,
* A Gemplus CCID based device

If you intend to use this driver with a different configuration (such
as a non x86 platform), please contact the support at the address
indicated at the very end of this document.

2. Installation

- Install the driver: # dpkg -i libccid_1.2.4-0_i386.deb

- Install the pcscd provided with this package:
# dpkg -i pcscd_1.2.9-beta9-0bpo1_i386.deb

The pcsc-lite daemon will (re)start automatically during installation.

3. Troubleshooting

For some Linux distributions, the pcmcia daemon should be loaded after
the pcscd daemon. As the pcscd daemon does not manage PCMCIA smart card
reader as hotplug devices, it might not take into account your GemPCCard
presence. To solve this issue, please restart the pcscd daemon as
explained below:

# /etc/init.d/pcscd restart

4. Release notes

Version 1.0.0: This is the initial driver version.
Version 1.1.0: Support of PCCard smart card reader and improvements.
Version 1.2.4: Support of PCPin PAD and GemPC Xpress smart card readers. "

This is a Debian Sarge package, I believe that I can use the alien trick on this package for OCE 4.5.

I can remove all of the packages I have installed before I run this. Please note, I am able to restart the pcscd dameon and also get a pcsc_scan result with my CAC card installed.

Essentially, I am unable to get Firefox to load a CAC module and use it. I have the required certs.

It seems that my middleware is missing. Coolkey is made for Lenny or Sid. I have seen some other middleware packages but they don't seem to help out at all. openct seems to create an installable device-yet is remains detached all the time.

I have also tried using the opensc/openct module *.s0 and that results in devices that are detached.




Last edited by Centurion030; 12-31-2008 at 12:35 AM.
Old 12-31-2008, 12:34 AM   #2
LQ Newbie
Registered: Nov 2008
Posts: 13

Original Poster
Rep: Reputation: 0
Thumbs up

First, I want to thank all the great folks from the Xandros forums, the AKO CAC forum, the Debian CoolKey maintainers, guys from work, and others for the help and assisstance in getting this project to work.

Here is how I got CoolKey to work on my Xandros OCE 4.5. (Debian "etch" Linux distro)

I first used Synaptic Package Manager with the following repositories (/etc/apt/sources.list)

deb oc4.5-xn main contrib non-free
deb etch main contrib non-free
deb p701 main
deb p900 main
deb p901 main
deb p904 main
deb p904hd main
deb p1000 main
deb p1000h main
deb p1000hd main
deb p701 main
deb p701 main etch
deb v104 main contrib non-free
deb v106 main contrib non-free

And, I got the following Libraries/Packages:
libccid 1.1.0-1
libpcsclite1 1.3.2-5
libpcsclite-dev 1.3.2-5
pcscd 1.3.2-5
pcsc-tools 1.4.8-1
libpcsc-perl 1.4.4-1

Because CoolKey doesn't exist as a package for my "etch" based distro, I got the source code for CoolKey.


* [coolkey_1.1.0-5.dsc] Description file
* [coolkey_1.1.0.orig.tar.gz] Actual code
* [coolkey_1.1.0-5.diff.gz] Patch

I saved them to a /coolkey/ directory.

I then used the following commands while in the coolkey directory.

tar -xvvzf coolkey_1.1.0.orig.tar.gz extract the files-creates coolkey-1.1.0/
gunzip coolkey_1.1.0-5.diff.gz unzip the diff file
patch --dry-run -p1 -i coolkey_1.1.0-5.diff do a dry run and test
patch -p0 <coolkey_1.1.0-5.diff patch the diff file to the source
cd coolkey-1.1.0/ cd to the directory
ls list everything
./configure configure
make compile
make install install

cd /
/etc/init.d/pcscd restart restart the pcscd daemon
pcsc_scan | more check for my card reader/card

find / -name * find the device module


/usr/local/lib/pkcs11/ this is what will be used

I installed the certificate authorities in Firefox. (Edit/Advanced/Security/View Certificates/

I then installed the security device in Firefox. (Edit/Advanced/Security Devices/Load)
I gave it a name "CAC Module" and browsed to /usr/local/lib/pkcs11/

I clicked "OK", clicked "OK" again for confirmation, and got the confirmation that a new security module was installed.

You can also login to your card in this menu as well. I tried out AKO and CAC login and it worked fine!

This was a good learning experience.



Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Installing Debian etch with usb pen - "ethernet card not found" alfmarius Linux - Networking 3 06-24-2008 10:51 AM
LXer: Installing Debian Etch From A Windows System With "Debian-Installer Loader" LXer Syndicated Linux News 0 09-28-2007 01:41 AM
LXer: DistroWatch Weekly: Overview of Debian and Mandriva, Debian 4.0 "Etch", SimplyMEPIS 6.5 LXer Syndicated Linux News 0 04-09-2007 06:46 AM
"Installing non-distro Linux on USB key" or "Using syslinux to boot a jffs2" lymae Linux - Newbie 6 12-31-2006 11:00 PM
USB smartcard reader akilles Linux - Newbie 3 11-16-2005 04:11 PM > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 04:34 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration