Discussion:
TCOS 2.0 Smartcard
Marcel Koopmans
2005-09-12 17:39:34 UTC
Permalink
Hello everybody,

So I tried the smartcard from my Kobil mIDentity in my Gemplus reader
and I cannot say I can do much more as with the GPK cards :-(

zeus:~# opensc-tool -av
Connecting to card in reader GemPC Twin 00 00...
Using card driver TCOS 2.0 cards.
Card ATR: 3B BA 96 00 81 31 86 5D 00 64 05 60 02 03 31 80 ;....1.].d.`..1.
90 00 66 ..f
zeus:~# opensc-explorer
OpenSC Explorer version 0.9.6
OpenSC [3F00]> info

Dedicated File ID 3F00

File path: 3F00
File size: 0 bytes
DF name: \xD2v\x00\x00\x03
ACL for SELECT: NONE
ACL for LOCK: NONE
ACL for DELETE: NONE
ACL for CREATE: NONE
ACL for REHABILITATE: NONE
ACL for INVALIDATE: NONE
ACL for LIST FILES: NONE
Proprietary attributes: 01
Security attributes: 60 00 00 00 FF FF A4 00 00 00 FF FF

OpenSC [3F00]> quit
zeus:~# pkcs15-init -EC -T
pkcs15-lib.c:298:sc_pkcs15init_bind: Unsupported card driver tcos

I hope that anybody can use this information.

with kind regards,
Marcel

Marcel Koopmans
Elysium Open Systems
Andreas Jellinghaus
2005-09-12 18:09:39 UTC
Permalink
Post by Marcel Koopmans
pkcs15-lib.c:298:sc_pkcs15init_bind: Unsupported card driver tcos
yep, tcos is not supported.

Regards, Andreas
Nils Larsch
2005-09-13 13:47:46 UTC
Permalink
Post by Andreas Jellinghaus
Post by Marcel Koopmans
pkcs15-lib.c:298:sc_pkcs15init_bind: Unsupported card driver tcos
yep, tcos is not supported.
yep, I guess the problem is that those who have blank tcos cards
don't have the time (and delight) or knowledge to write such a
driver and those who are familiar with the code and perhaps willing to
do so don't have blank tcos cards :-(

Cheers,
Nils
Peter Koch
2005-09-13 14:09:43 UTC
Permalink
Post by Nils Larsch
Post by Andreas Jellinghaus
Post by Marcel Koopmans
pkcs15-lib.c:298:sc_pkcs15init_bind: Unsupported card driver tcos
yep, tcos is not supported.
yep, I guess the problem is that those who have blank tcos cards
don't have the time (and delight) or knowledge to write such a
driver and those who are familiar with the code and perhaps willing to
do so don't have blank tcos cards :-(
Cheers,
Nils
If I remember this right, Werner Koch programmed a pkcs15-init routine
for tcos cards and this was in a former OpenSC version.

So where is this old routine?

Peter
--
GMX DSL = Maximale Leistung zum minimalen Preis!
2000 MB nur 2,99, Flatrate ab 4,99 Euro/Monat: http://www.gmx.net/de/go/dsl
Andreas Jellinghaus
2005-09-13 15:55:36 UTC
Permalink
Post by Peter Koch
If I remember this right, Werner Koch programmed a pkcs15-init routine
for tcos cards and this was in a former OpenSC version.
So where is this old routine?
ftp://ftp.gnupg.org/gcrypt/alpha/aegypten/

Andreas
Peter Koch
2005-09-13 06:08:01 UTC
Permalink
Post by Andreas Jellinghaus
Post by Marcel Koopmans
pkcs15-lib.c:298:sc_pkcs15init_bind: Unsupported card driver tcos
yep, tcos is not supported.
OpenSC cannot create a pkcs15 layout on empty TCOS cards.
But OpenSC can use some preformatted TCOS cards.

Have a look at the OpenSC Wiki and get the latest CVS-version.

Please send me opensc-tool -dddddd -f output. I'm trying to
add support for all kinds of TCOS based preformatted cards to
OpenSC and if you are willing to do some tests your card may
be supported soon.

Peter
Post by Andreas Jellinghaus
Regards, Andreas
_______________________________________________
opensc-user mailing list
http://www.opensc.org/cgi-bin/mailman/listinfo/opensc-user
--
GMX DSL = Maximale Leistung zum minimalen Preis!
2000 MB nur 2,99, Flatrate ab 4,99 Euro/Monat: http://www.gmx.net/de/go/dsl
Marcel Koopmans
2005-09-13 15:36:16 UTC
Permalink
Hello Peter,

This is the requested output.

zeus:~# opensc-tool -vvvvvv -f
sc.c:120:sc_detect_card_presence: called
sc.c:125:sc_detect_card_presence: returning with: 1
Connecting to card in reader GemPC Twin 00 00...
card.c:346:sc_connect_card: called
reader-pcsc.c:406:pcsc_connect: Looking for a card_atr
3b:ba:96:00:81:31:86:5d:00:64:05:60:02:03:31:80:90:00:66
card.c:401:sc_connect_card: trying driver: Siemens CardOS
card.c:401:sc_connect_card: trying driver: Schlumberger Multiflex/Cryptoflex
card.c:401:sc_connect_card: trying driver: Schlumberger Cyberflex
card.c:401:sc_connect_card: trying driver: Gemplus GPK driver
card.c:401:sc_connect_card: trying driver: MioCOS 1.1 cards
card.c:401:sc_connect_card: trying driver: MICARDO 2.1
card.c:401:sc_connect_card: trying driver: Setec smartcards
card.c:401:sc_connect_card: trying driver: driver for STARCOS SPK 2.3 cards
card.c:401:sc_connect_card: trying driver: TCOS 2.0 cards
card.c:407:sc_connect_card: matched: TCOS 2.0 cards
card.c:431:sc_connect_card: returning with: 0
Using card driver TCOS 2.0 cards.
card.c:468:sc_lock: called
card.c:691:sc_select_file: called; type=2, path=3f00
card.c:229:sc_transmit_apdu: called
card.c:196:sc_transceive: Sending 8 bytes (resp. 260 bytes):
00 A4 00 00 02 3F 00 FF .....?..
card.c:249:sc_transmit_apdu: Received 33 bytes (SW1=90 SW2=00)
6F 1F 83 02 3F 00 82 01 38 85 01 01 84 05 D2 76 o...?...8......v
00 00 03 86 0C 60 00 00 00 FF FF A4 00 00 00 FF .....`..........
FF .
card-tcos.c:337:tcos_process_fci: processing FCI bytes
card-tcos.c:343:tcos_process_fci: file identifier: 0x3F00
card-tcos.c:370:tcos_process_fci: shareable: no
card-tcos.c:390:tcos_process_fci: type: DF
card-tcos.c:392:tcos_process_fci: EF structure: 0
card-tcos.c:413:tcos_process_fci: File name: ?v???
card.c:713:sc_select_file: returning with: 0
3F00 [\xD2v\x00\x00\x03] type: DF, size: 0
select[NONE] lock[NONE] delete[NONE] create[NONE] rehab[NONE]
inval[NONE] list[NONE] sec: 60:00:00:00:FF:FF:A4:00:00:00:FF:FF
prop: 01

card.c:514:sc_list_files: called
card.c:229:sc_transmit_apdu: called
card.c:196:sc_transceive: Sending 5 bytes (resp. 260 bytes):
80 AA 01 00 00 .....
card.c:249:sc_transmit_apdu: Received 0 bytes (SW1=6A SW2=82)
iso7816.c:98:iso7816_check_sw: File not found
card.c:229:sc_transmit_apdu: called
card.c:196:sc_transceive: Sending 5 bytes (resp. 260 bytes):
80 AA 02 00 00 .....
card.c:249:sc_transmit_apdu: Received 4 bytes (SW1=90 SW2=00)
44 00 2F 02 D./.
card.c:518:sc_list_files: returning with: 4
card.c:691:sc_select_file: called; type=2, path=3f004400
card.c:229:sc_transmit_apdu: called
card.c:196:sc_transceive: Sending 8 bytes (resp. 260 bytes):
00 A4 08 00 02 44 00 FF .....D..
card.c:249:sc_transmit_apdu: Received 43 bytes (SW1=90 SW2=00)
6F 29 83 02 44 00 81 02 00 1A 82 03 03 41 1A 85 o)..D........A..
06 01 C3 00 0C 05 05 86 12 DC 00 01 00 FF FF 82 ................
00 00 00 FF FF EE 00 00 00 FF FF ...........
card-tcos.c:337:tcos_process_fci: processing FCI bytes
card-tcos.c:343:tcos_process_fci: file identifier: 0x4400
card-tcos.c:349:tcos_process_fci: bytes in file: 26
card-tcos.c:370:tcos_process_fci: shareable: no
card-tcos.c:390:tcos_process_fci: type: working EF
card-tcos.c:392:tcos_process_fci: EF structure: 3
card.c:713:sc_select_file: returning with: 0
3F00 4400 type: wEF, ef structure: linrfix(TLV), size: 26
read[NONE] update[NONE] write[TERM] erase[NONE] rehab[N/A] inval[N/A]
sec: DC:00:01:00:FF:FF:82:00:00:00:FF:FF:EE:00:00:00:FF:FF
prop: 01:C3:00:0C:05:05

card.c:691:sc_select_file: called; type=2, path=3f002f02
card.c:229:sc_transmit_apdu: called
card.c:196:sc_transceive: Sending 8 bytes (resp. 260 bytes):
00 A4 08 00 02 2F 02 FF ...../..
card.c:249:sc_transmit_apdu: Received 31 bytes (SW1=90 SW2=00)
6F 1D 83 02 2F 02 81 02 00 0C 82 01 01 85 02 01 o.../...........
02 86 0C B0 00 00 00 FF FF EE 00 00 00 FF FF ...............
card-tcos.c:337:tcos_process_fci: processing FCI bytes
card-tcos.c:343:tcos_process_fci: file identifier: 0x2F02
card-tcos.c:349:tcos_process_fci: bytes in file: 12
card-tcos.c:370:tcos_process_fci: shareable: no
card-tcos.c:390:tcos_process_fci: type: working EF
card-tcos.c:392:tcos_process_fci: EF structure: 1
card.c:713:sc_select_file: returning with: 0
3F00 2F02 type: wEF, ef structure: transpnt, size: 12
read[NONE] update[NONE] write[N/A] erase[NONE] rehab[N/A] inval[N/A]
sec: B0:00:00:00:FF:FF:EE:00:00:00:FF:FF
prop: 01:02

card.c:563:sc_read_binary: called; 12 bytes at index 0
card.c:229:sc_transmit_apdu: called
card.c:196:sc_transceive: Sending 5 bytes (resp. 14 bytes):
00 B0 00 00 0C .....
card.c:249:sc_transmit_apdu: Received 12 bytes (SW1=90 SW2=00)
5A 0A 89 49 01 72 00 00 26 43 02 80 Z..I.r..&C..
iso7816.c:126:iso7816_read_binary: returning with: 12
card.c:594:sc_read_binary: returning with: 12
00000000: 5A 0A 89 49 01 72 00 00 26 43 02 80 Z..I.r..&C..
card.c:488:sc_unlock: called
card.c:493:sc_unlock: Calling card logout function
card.c:691:sc_select_file: called; type=2, path=3f00
card.c:229:sc_transmit_apdu: called
card.c:196:sc_transceive: Sending 8 bytes (resp. 260 bytes):
00 A4 00 00 02 3F 00 FF .....?..
card.c:249:sc_transmit_apdu: Received 33 bytes (SW1=90 SW2=00)
6F 1F 83 02 3F 00 82 01 38 85 01 01 84 05 D2 76 o...?...8......v
00 00 03 86 0C 60 00 00 00 FF FF A4 00 00 00 FF .....`..........
FF .
card-tcos.c:501:hacked_iso7816_select_file: returning with: 0
card.c:713:sc_select_file: returning with: 0
card.c:443:sc_disconnect_card: called
card.c:458:sc_disconnect_card: returning with: 0
ctx.c:618:sc_release_context: called
reader-openct.c:171:openct_reader_release: called
reader-openct.c:171:openct_reader_release: called
reader-openct.c:171:openct_reader_release: called
reader-openct.c:171:openct_reader_release: called
reader-openct.c:171:openct_reader_release: called
reader-openct.c:157:openct_reader_finish: called


with kind regards,
Marcel

Marcel Koopmans
Elysium Open Systems
Post by Peter Koch
Post by Andreas Jellinghaus
Post by Marcel Koopmans
pkcs15-lib.c:298:sc_pkcs15init_bind: Unsupported card driver tcos
yep, tcos is not supported.
OpenSC cannot create a pkcs15 layout on empty TCOS cards.
But OpenSC can use some preformatted TCOS cards.
Have a look at the OpenSC Wiki and get the latest CVS-version.
Please send me opensc-tool -dddddd -f output. I'm trying to
add support for all kinds of TCOS based preformatted cards to
OpenSC and if you are willing to do some tests your card may
be supported soon.
Peter
Post by Andreas Jellinghaus
Regards, Andreas
_______________________________________________
opensc-user mailing list
http://www.opensc.org/cgi-bin/mailman/listinfo/opensc-user
Peter Koch
2005-09-13 19:33:41 UTC
Permalink
Post by Marcel Koopmans
This is the requested output.
zeus:~# opensc-tool -vvvvvv -f
....
Your card is almost empty. There are only two
files on it and no subdirectories

1.File: 2F02
This finle contains the serial number of your
card, i.e. 8949017200002643028

2.File: 4400
This file contains a 3DES-key which may be used
for administrative puroses (this is what the
TCOS manual says about file 4400 - I have no idea
what administrative purposes this may be)

So the final conclusion is: Your card is empty.
If you want to use it with OpenSC someone has
to write a pkcs15-init routine first.

Or you may use software from Kobil to create files
on your card. To find out whether files created by
Kobils mIdentity software can be used by OpenSC
I need opensc -f output from a card that has
such files.

Peter
--
Lust, ein paar Euro nebenbei zu verdienen? Ohne Kosten, ohne Risiko!
Satte Provisionen f�r GMX Partner: http://www.gmx.net/de/go/partner
Loading...