Pier Paolo Bortone | 3 Oct 12:09 2005
Picon

R: [Snapshot] - Help - Win32 0.9.6 Snapshot

Hi Andreas,
thanks for your answer.

Now I cannot launch build on windows, I will do it in the next future.

I tried to install scb (scb-0.5-pre1e.exe) but I got the same problem.

For example, if I execute command: pkcs11-tool -l -t
this is the output from opensc-errors.log:
File not found
card-starcos.c:317:starcos_select_fid: returning with: File not found
card.c:759:sc_select_file: returning with: File not found
X.509 certificate not found
Conditions of use not satisfied
card-starcos.c:1152:starcos_set_security_env: returning with: Not allowed
sec.c:67:sc_set_security_env: returning with: Not allowed
pkcs15-sec.c:312:sc_pkcs15_compute_signature: sc_set_security_env() failed: Not allowed

I think that the malfunctioning is due to this version of opensc,
looking the log file seems that the version is 0.9.4. Is it true?

Doesn't exist a version of scb with opensc 0.9.6?

I can upload the opensc-debug.log if it is necessary.

The card I'm trying to read is
InfoCamere 1202 series card (with STARCOS SPK 2.3).

Thanks in advance for the support.

(Continue reading)

Andreas Jellinghaus | 3 Oct 23:25 2005
Picon

Re: R: [Snapshot] - Help - Win32 0.9.6 Snapshot

Hi Pier,

> I tried to install scb (scb-0.5-pre1e.exe) but I got the same problem.

sorry to hear that.

> For example, if I execute command: pkcs11-tool -l -t
> this is the output from opensc-errors.log:
> File not found
> card-starcos.c:317:starcos_select_fid: returning with: File not found
> card.c:759:sc_select_file: returning with: File not found
> X.509 certificate not found
> Conditions of use not satisfied
> card-starcos.c:1152:starcos_set_security_env: returning with: Not allowed
> sec.c:67:sc_set_security_env: returning with: Not allowed
> pkcs15-sec.c:312:sc_pkcs15_compute_signature: sc_set_security_env() failed: 
Not allowed

hmm. I'm no expert on starcos etc., so I hope someone else can comment on
that. But I guess they need more details. (i.e. which file was not found
and so on). please increase debugging in the opensc config file.

> I think that the malfunctioning is due to this version of opensc,
> looking the log file seems that the version is 0.9.4. Is it true?
> 
> Doesn't exist a version of scb with opensc 0.9.6?

scb 0.4.0 is opensc 0.9.6 and 0.5.0 will use opensc 0.10.0.

Andreas
(Continue reading)

Holger Lange | 4 Oct 09:13 2005
Picon

How to protect certificates on Cryptoflex

Hi all,

I want to store a trusted certificate on a Cryptoflex 16k and write protect it with the user PIN.
Therefor I changed "protect_certificates" in  flex.profile to "yes" and adjusted the size of the DFs accordingly.
With a blank card I did:

pkcs15-init --create-pkcs15 --use-default-transport-keys
pkcs15-init --store-pin --auth-id 01
pkcs15-init --store-certificate mycert.pem --auth-id 01

All operations returned without an error. But the certificate file was created under DF 5015 and not DF 5015/4B01 and so the certificate is'nt protected.

Looking at the source it seems, that --auth-id is ignored with --store-certificate. Is there any way to protect certificates with pkcs15-init on Cryptoflex? Do I have to apply further changes to fl ex.profile?

Thank you for your help!

Best regards

Holger

!

Erweitern Sie FreeMail zu einem noch leistungsstarkeren E-Mail-Postfach!    
Mehr Infos unter http://freemail.web.de/home/landingpad/?mc=021131  
<div>
<p>Hi all,</p>
<p>I want to store a trusted certificate on a Cryptoflex 16k and write protect it with the user PIN. <br>Therefor I&nbsp;changed "protect_certificates" in&nbsp;&nbsp;flex.profile to "yes" and adjusted the size of the DFs accordingly.<br>With a blank card I did:<br><br>pkcs15-init --create-pkcs15 --use-default-transport-keys<br>pkcs15-init --store-pin --auth-id 01<br>pkcs15-init --store-certificate mycert.pem --auth-id 01<br><br>All operations returned without an error. But the certificate file was created under DF 5015 and not DF 5015/4B01 and so the certificate is'nt protected.<br><br>Looking at the source it seems, that --auth-id is ignored with --store-certificate. Is there any way to protect certificates with pkcs15-init on Cryptoflex? Do I have to apply further changes to fl
 ex.profile?<br><br>Thank you for your help!<br><br>Best regards<br><br>Holger<br><br></p>!
 <br><br><table cellpadding="0" cellspacing="0" border="0">
<tr><td bgcolor="#000000"></td></tr>
<tr><td>Erweitern Sie FreeMail zu einem noch leistungsstarkeren E-Mail-Postfach!		&nbsp;&nbsp;&nbsp;<br>Mehr Infos unter <a href="http://freemail.web.de/home/landingpad/?mc=021131">http://freemail.web.de/home/landingpad/?mc=021131</a>&nbsp;&nbsp;</td></tr>
</table>
</div>
Pier Paolo Bortone | 4 Oct 19:20 2005
Picon

R: R: [Snapshot] - Help - Win32 0.9.6 Snapshot

Hi Andreas,
I posted another message with detail of my card problem.

I want to tell you I succesfully installed SCB modifying somethings:
in file opensc.conf I changed
	profile_dir = PKGDATADIR; 
to
	profile_dir = "C:\Programmi\Smart Card Bundle";

Thanks.

Pier Paolo.

-----Messaggio originale-----
Da: opensc-user-bounces <at> lists.opensc.org [mailto:opensc-user-bounces <at> lists.opensc.org] Per
conto di Andreas Jellinghaus
Inviato: lunedì 3 ottobre 2005 23.26
Cc: opensc-user <at> lists.opensc.org
Oggetto: Re: R: [opensc-user] [Snapshot] - Help - Win32 0.9.6 Snapshot

Hi Pier,

> I tried to install scb (scb-0.5-pre1e.exe) but I got the same problem.

sorry to hear that.

> For example, if I execute command: pkcs11-tool -l -t this is the 
> output from opensc-errors.log:
> File not found
> card-starcos.c:317:starcos_select_fid: returning with: File not found
> card.c:759:sc_select_file: returning with: File not found
> X.509 certificate not found
> Conditions of use not satisfied
> card-starcos.c:1152:starcos_set_security_env: returning with: Not 
> allowed
> sec.c:67:sc_set_security_env: returning with: Not allowed
> pkcs15-sec.c:312:sc_pkcs15_compute_signature: sc_set_security_env() failed: 
Not allowed

hmm. I'm no expert on starcos etc., so I hope someone else can comment on that. But I guess they need more
details. (i.e. which file was not found and so on). please increase debugging in the opensc config file.

> I think that the malfunctioning is due to this version of opensc, 
> looking the log file seems that the version is 0.9.4. Is it true?
> 
> Doesn't exist a version of scb with opensc 0.9.6?

scb 0.4.0 is opensc 0.9.6 and 0.5.0 will use opensc 0.10.0.

Andreas
_______________________________________________
opensc-user mailing list
opensc-user <at> lists.opensc.org
http://www.opensc.org/cgi-bin/mailman/listinfo/opensc-user

Pier Paolo Bortone | 4 Oct 18:48 2005
Picon

[INFOCAMERE STARCOS 2.3 CARD] Invalid ASN.1 object

Hi all,
finally I succesfully installed SCB (scb-0.5-pre1e.exe).
 
Anyway my problem with InfoCamere 1202 card (STARCOS 2.3) remains.
 
Now, I try to list all necessary elements (3 commands) to analize this problem.

NOTE: I tested card with InfoCamere owner product
        (Dike) http://www.card.infocamere.it/software/software_home.htm
        and all seems to run correctly.
 
If someone needs further specific elements, please let me know.
       
Thanks in advance at all.
 
First element *********************************************************
DUMP COMMAND RESULT + RELATIVE ERRORS LOG
C:\Programmi\Smart card bundle>p15dump.exe
Using libopensc version 0.9.4.
Card detected in reader 'CASTLES EZ100PU 0'
Connecting... connected.
ATR = 3b:b7:94:00:81:31:fe:65:53:50:4b:32:33:90:00:d1
Looking for a PKCS#15 compatible Smart Card... found.
PKCS#15 Card [Infocamere 1202 Card]:
        Version        : 0
        Serial number  : d2760000012590154800131c13
        Manufacturer ID: Infocamere
        Flags          :
Enumerating PIN codes... 1 found.
PIN [Non-repudiation PIN]
        Com. Flags  : private, modifiable
        Auth ID     : 02
        Flags       : [0x31], case-sensitive, initialized, needs-padding
        Length      : min_len:5, max_len:8, stored_len:8
        Pad char    : 0x00
        Reference   : 153
        Encoding    : ASCII-numeric
        Path        : 3F00DF01
        Tries left  : 3
Enumerating Private keys... 1 found.
Private RSA key [Non repudiation Key]
        Com. Flags  : private
        Com. Auth ID: 02
        Usage       : [0x200], nonRepudiation
        Access Flags: [0x1D], sensitive, alwaysSensitive, neverExtract, local
        ModLength   : 1024
        Key ref     : 132
        Native      : yes
        Path        : 3F00DF01
        ID          : 02
Enumerating Public keys... none found.
Enumerating X.509 certificates... 2 found.
X.509 Certificate [User Non-repudiation Certificate]
        Com. Flags  : modifiable
        Authority   : no
        Path        : df01c000
        ID          : 02
X.509 Certificate [CA Certificate]
        Com. Flags  : modifiable
        Authority   : yes
        Path        : df01c008
        ID          : 03
Enumerating data objects... none found.
 
opensc-errors.log:
 
File not found
card-starcos.c:317:starcos_select_fid: returning with: File not found
card.c:759:sc_select_file: returning with: File not found
***********************************************************************
 
Second element ********************************************************
TRY TO READ CERTIFICATE WITH ID 03 + RELATIVE DEBUG & ERRORS LOG
C:\Programmi\Smart card bundle>pkcs15-tool.exe --read-certificate 03
Certificate read failed: Invalid ASN.1 object
 
opensc-errors.log:
 
File not found
card-starcos.c:317:starcos_select_fid: returning with: File not found
card.c:759:sc_select_file: returning with: File not found
X.509 certificate not found
 
opensc-debug.log: (I omitted pre-card-matching debug)
 
opensc version: 0.9.4
sc.c:142:sc_detect_card_presence: called
sc.c:147:sc_detect_card_presence: returning with: 1
card.c:368:sc_connect_card: called
ATR     : 3b:b7:94:00:81:31:fe:65:53:50:4b:32:33:90:00:d1
ATR try : 3b:6e:00:ff:45:73:74:45:49:44:20:76:65:72:20:31:2e:30
ATR try : 3b:fe:94:00:ff:80:b1:fa:45:1f:03:45:73:74:45:49:44:20:76:65:72:20:31:2e:30:43
matching configured ATRs
matching built-in ATRs
... omitted ...
trying driver: starcos
ATR     : 3b:b7:94:00:81:31:fe:65:53:50:4b:32:33:90:00:d1
ATR try : 3B:B7:94:00:c0:24:31:fe:65:53:50:4b:32:33:90:00:b4
ATR try : 3B:B7:94:00:81:31:fe:65:53:50:4b:32:33:90:00:d1
matched: STARCOS SPK 2.3
card info: STARCOS SPK 2.3, 7001, 0x0
card.c:477:sc_connect_card: returning with: 0
card.c:514:sc_lock: called
pkcs15.c:611:sc_pkcs15_bind: called
trying normal pkcs15 processing
called; type=2, path=3f002f00
card-starcos.c:375:starcos_select_file: called
current path (path, valid):  (len: 0)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 3F 00 00 .....?..
Received 0 bytes (SW1=62 SW2=84)
card.c:250:sc_transmit_apdu: called
Sending 7 bytes (resp. 258 bytes):
00 A4 00 0C 02 3F 00 .....?.
Received 0 bytes (SW1=90 SW2=00)
card-starcos.c:361:starcos_select_fid: returning with: 0
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 2F 00 00 ...../..
Received 0 bytes (SW1=6A SW2=82)
sw1 = 0x6a, sw2 = 0x82
File not found
card-starcos.c:317:starcos_select_fid: returning with: -1201
card.c:759:sc_select_file: returning with: -1201
called; type=2, path=3f005015
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F00 (len: 2)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 50 15 00 .....P..
Received 0 bytes (SW1=6A SW2=82)
sw1 = 0x6a, sw2 = 0x82
File not found
card-starcos.c:317:starcos_select_fid: returning with: -1201
card.c:759:sc_select_file: returning with: -1201
called; type=2, path=3f005031
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F00 (len: 2)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 50 31 00 .....P1.
Received 0 bytes (SW1=6A SW2=82)
sw1 = 0x6a, sw2 = 0x82
pkcs15-syn.c:85:sc_pkcs15_bind_synthetic: called
use builtin drivers
trying esteid
trying openpgp
trying tcos
trying starcert
called; type=2, path=3f00fe13
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F00 (len: 2)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 FE 13 00 ........
Received 0 bytes (SW1=6A SW2=82)
sw1 = 0x6a, sw2 = 0x82
File not found
card-starcos.c:317:starcos_select_fid: returning with: -1201
card.c:759:sc_select_file: returning with: -1201
trying infocamere
called; type=2, path=3f002f02
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F00 (len: 2)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 2F 02 00 ...../..
Received 9 bytes (SW1=90 SW2=00)
6F 07 80 02 00 1A 82 01 01 o........
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 00 00 01 .....
Received 1 bytes (SW1=90 SW2=00)
5A Z
processing FCI bytes
  bytes in file: 26
  type: working EF
  EF structure: transparent
card-starcos.c:361:starcos_select_fid: returning with: 0
card.c:759:sc_select_file: returning with: 0
called; 26 bytes at index 0
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 00 00 1A .....
Received 26 bytes (SW1=90 SW2=00)
5A 0D D2 76 00 00 01 25 90 15 48 00 13 1C 13 5F Z..v...%..H...._
20 08 12 02 05 00 00 77 78 25                    ......wx%
iso7816.c:126:iso7816_read_binary: returning with: 26
card.c:640:sc_read_binary: returning with: 26
called; type=2, path=11111a02
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F00 (len: 2)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 11 11 00 ........
Received 0 bytes (SW1=62 SW2=84)
card.c:250:sc_transmit_apdu: called
Sending 7 bytes (resp. 258 bytes):
00 A4 00 0C 02 11 11 .......
Received 0 bytes (SW1=90 SW2=00)
card-starcos.c:361:starcos_select_fid: returning with: 0
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F001111 (len: 4)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 1A 02 00 ........
Received 0 bytes (SW1=6A SW2=82)
sw1 = 0x6a, sw2 = 0x82
File not found
card-starcos.c:317:starcos_select_fid: returning with: -1201
card.c:759:sc_select_file: returning with: -1201
called; type=2, path=df01c000
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F001111 (len: 4)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 DF 01 00 ........
Received 0 bytes (SW1=62 SW2=84)
card.c:250:sc_transmit_apdu: called
Sending 7 bytes (resp. 258 bytes):
00 A4 00 0C 02 DF 01 .......
Received 0 bytes (SW1=90 SW2=00)
card-starcos.c:361:starcos_select_fid: returning with: 0
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F00DF01 (len: 4)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 C0 00 00 ........
Received 9 bytes (SW1=90 SW2=00)
6F 07 80 02 0A 00 82 01 01 o........
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 00 00 01 .....
Received 1 bytes (SW1=90 SW2=00)
08 .
card-starcos.c:361:starcos_select_fid: returning with: 0
card.c:759:sc_select_file: returning with: 0
called; 2 bytes at index 0
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 00 00 02 .....
Received 2 bytes (SW1=90 SW2=00)
08 05 ..
iso7816.c:126:iso7816_read_binary: returning with: 2
card.c:640:sc_read_binary: returning with: 2
called; type=2, path=df01c008
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F00DF01 (len: 4)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 C0 08 00 ........
Received 9 bytes (SW1=90 SW2=00)
6F 07 80 02 06 00 82 01 01 o........
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 00 00 01 .....
Received 1 bytes (SW1=90 SW2=00)
00 .
card-starcos.c:361:starcos_select_fid: returning with: 0
card.c:759:sc_select_file: returning with: 0
called; 2 bytes at index 0
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 00 00 02 .....
Received 2 bytes (SW1=90 SW2=00)
00 00 ..
iso7816.c:126:iso7816_read_binary: returning with: 2
card.c:640:sc_read_binary: returning with: 2
called; type=2, path=3f00
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F00DF01 (len: 4)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 3F 00 00 .....?..
Received 0 bytes (SW1=62 SW2=84)
card.c:250:sc_transmit_apdu: called
Sending 7 bytes (resp. 258 bytes):
00 A4 00 0C 02 3F 00 .....?.
Received 0 bytes (SW1=90 SW2=00)
card-starcos.c:361:starcos_select_fid: returning with: 0
card.c:759:sc_select_file: returning with: 0
pkcs15-cert.c:115:sc_pkcs15_read_certificate: called
called, path=df01c008, index=2, count=0
called; type=2, path=df01c008
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F00 (len: 2)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 DF 01 00 ........
Received 0 bytes (SW1=62 SW2=84)
card.c:250:sc_transmit_apdu: called
Sending 7 bytes (resp. 258 bytes):
00 A4 00 0C 02 DF 01 .......
Received 0 bytes (SW1=90 SW2=00)
card-starcos.c:361:starcos_select_fid: returning with: 0
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F00DF01 (len: 4)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 C0 08 00 ........
Received 9 bytes (SW1=90 SW2=00)
6F 07 80 02 06 00 82 01 01 o........
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 00 00 01 .....
Received 1 bytes (SW1=90 SW2=00)
00 .
processing FCI bytes
  bytes in file: 1536
  type: working EF
  EF structure: transparent
card-starcos.c:361:starcos_select_fid: returning with: 0
card.c:759:sc_select_file: returning with: 0
called; 0 bytes at index 2
pkcs15.c:686:sc_pkcs15_unbind: called
card.c:534:sc_unlock: called
Calling card logout function
card.c:250:sc_transmit_apdu: called
Sending 7 bytes (resp. 258 bytes):
00 A4 00 0C 02 3F 00 .....?.
Received 0 bytes (SW1=90 SW2=00)
sw1 = 0x90, sw2 = 0x00
card.c:489:sc_disconnect_card: called
card.c:504:sc_disconnect_card: returning with: 0
ctx.c:709:sc_release_context: called
***********************************************************************
 
Third element *********************************************************
PKCS11 TEST COMMAND + RELATIVE DEBUG & ERRORS LOG
C:\Programmi\Smart card bundle>pkcs11-tool.exe --login --test
Please enter User PIN:
C_SeedRandom() and C_GenerateRandom():
  not implemented
Digests:
  all 4 digest functions seem to work
  MD5: OK
  SHA-1: OK
  RIPEMD160: OK
Signatures (currently only RSA signatures)
  testing key 0 (Non repudiation Key)
error: PKCS11 function C_SignFinal failed: rv = CKR_GENERAL_ERROR (0x5)
Aborting.
 
opensc-errors.log:
 
File not found
card-starcos.c:317:starcos_select_fid: returning with: File not found
card.c:759:sc_select_file: returning with: File not found
X.509 certificate not found
Conditions of use not satisfied
card-starcos.c:1152:starcos_set_security_env: returning with: Not allowed
sec.c:67:sc_set_security_env: returning with: Not allowed
pkcs15-sec.c:312:sc_pkcs15_compute_signature: sc_set_security_env() failed: Not allowed
 
opensc-debug.log: (I omitted pre-card-matching debug)
 
opensc version: 0.9.4
0: Detecting smart card
sc.c:142:sc_detect_card_presence: called
sc.c:147:sc_detect_card_presence: returning with: 1
0: Connecting to smart card
card.c:368:sc_connect_card: called
ATR     : 3b:b7:94:00:81:31:fe:65:53:50:4b:32:33:90:00:d1
ATR try : 3b:6e:00:ff:45:73:74:45:49:44:20:76:65:72:20:31:2e:30
ATR try : 3b:fe:94:00:ff:80:b1:fa:45:1f:03:45:73:74:45:49:44:20:76:65:72:20:31:2e:30:43
matching configured ATRs
matching built-in ATRs
... omitted ...
trying driver: starcos
ATR     : 3b:b7:94:00:81:31:fe:65:53:50:4b:32:33:90:00:d1
ATR try : 3B:B7:94:00:c0:24:31:fe:65:53:50:4b:32:33:90:00:b4
ATR try : 3B:B7:94:00:81:31:fe:65:53:50:4b:32:33:90:00:d1
matched: STARCOS SPK 2.3
card info: STARCOS SPK 2.3, 7001, 0x0
card.c:477:sc_connect_card: returning with: 0
0: Detecting Framework
pkcs15.c:611:sc_pkcs15_bind: called
card.c:514:sc_lock: called
trying normal pkcs15 processing
called; type=2, path=3f002f00
card-starcos.c:375:starcos_select_file: called
current path (path, valid):  (len: 0)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 3F 00 00 .....?..
Received 0 bytes (SW1=62 SW2=84)
card.c:250:sc_transmit_apdu: called
Sending 7 bytes (resp. 258 bytes):
00 A4 00 0C 02 3F 00 .....?.
Received 0 bytes (SW1=90 SW2=00)
card-starcos.c:361:starcos_select_fid: returning with: 0
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 2F 00 00 ...../..
Received 0 bytes (SW1=6A SW2=82)
sw1 = 0x6a, sw2 = 0x82
File not found
card-starcos.c:317:starcos_select_fid: returning with: -1201
card.c:759:sc_select_file: returning with: -1201
called; type=2, path=3f005015
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F00 (len: 2)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 50 15 00 .....P..
Received 0 bytes (SW1=6A SW2=82)
sw1 = 0x6a, sw2 = 0x82
File not found
card-starcos.c:317:starcos_select_fid: returning with: -1201
card.c:759:sc_select_file: returning with: -1201
called; type=2, path=3f005031
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F00 (len: 2)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 50 31 00 .....P1.
Received 0 bytes (SW1=6A SW2=82)
sw1 = 0x6a, sw2 = 0x82
pkcs15-syn.c:85:sc_pkcs15_bind_synthetic: called
use builtin drivers
trying esteid
trying openpgp
trying tcos
trying starcert
called; type=2, path=3f00fe13
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F00 (len: 2)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 FE 13 00 ........
Received 0 bytes (SW1=6A SW2=82)
sw1 = 0x6a, sw2 = 0x82
File not found
card-starcos.c:317:starcos_select_fid: returning with: -1201
card.c:759:sc_select_file: returning with: -1201
trying infocamere
called; type=2, path=3f002f02
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F00 (len: 2)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 2F 02 00 ...../..
Received 9 bytes (SW1=90 SW2=00)
6F 07 80 02 00 1A 82 01 01 o........
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 00 00 01 .....
Received 1 bytes (SW1=90 SW2=00)
5A Z
processing FCI bytes
  bytes in file: 26
  type: working EF
  EF structure: transparent
card-starcos.c:361:starcos_select_fid: returning with: 0
card.c:759:sc_select_file: returning with: 0
called; 26 bytes at index 0
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 00 00 1A .....
Received 26 bytes (SW1=90 SW2=00)
5A 0D D2 76 00 00 01 25 90 15 48 00 13 1C 13 5F Z..v...%..H...._
20 08 12 02 05 00 00 77 78 25                    ......wx%
iso7816.c:126:iso7816_read_binary: returning with: 26
card.c:640:sc_read_binary: returning with: 26
called; type=2, path=11111a02
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F00 (len: 2)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 11 11 00 ........
Received 0 bytes (SW1=62 SW2=84)
card.c:250:sc_transmit_apdu: called
Sending 7 bytes (resp. 258 bytes):
00 A4 00 0C 02 11 11 .......
Received 0 bytes (SW1=90 SW2=00)
card-starcos.c:361:starcos_select_fid: returning with: 0
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F001111 (len: 4)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 1A 02 00 ........
Received 0 bytes (SW1=6A SW2=82)
sw1 = 0x6a, sw2 = 0x82
File not found
card-starcos.c:317:starcos_select_fid: returning with: -1201
card.c:759:sc_select_file: returning with: -1201
called; type=2, path=df01c000
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F001111 (len: 4)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 DF 01 00 ........
Received 0 bytes (SW1=62 SW2=84)
card.c:250:sc_transmit_apdu: called
Sending 7 bytes (resp. 258 bytes):
00 A4 00 0C 02 DF 01 .......
Received 0 bytes (SW1=90 SW2=00)
card-starcos.c:361:starcos_select_fid: returning with: 0
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F00DF01 (len: 4)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 C0 00 00 ........
Received 9 bytes (SW1=90 SW2=00)
6F 07 80 02 0A 00 82 01 01 o........
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 00 00 01 .....
Received 1 bytes (SW1=90 SW2=00)
08 .
card-starcos.c:361:starcos_select_fid: returning with: 0
card.c:759:sc_select_file: returning with: 0
called; 2 bytes at index 0
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 00 00 02 .....
Received 2 bytes (SW1=90 SW2=00)
08 05 ..
iso7816.c:126:iso7816_read_binary: returning with: 2
card.c:640:sc_read_binary: returning with: 2
called; type=2, path=df01c008
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F00DF01 (len: 4)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 C0 08 00 ........
Received 9 bytes (SW1=90 SW2=00)
6F 07 80 02 06 00 82 01 01 o........
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 00 00 01 .....
Received 1 bytes (SW1=90 SW2=00)
00 .
card-starcos.c:361:starcos_select_fid: returning with: 0
card.c:759:sc_select_file: returning with: 0
called; 2 bytes at index 0
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 00 00 02 .....
Received 2 bytes (SW1=90 SW2=00)
00 00 ..
iso7816.c:126:iso7816_read_binary: returning with: 2
card.c:640:sc_read_binary: returning with: 2
called; type=2, path=3f00
card-starcos.c:375:starcos_select_file: called
current path (path, valid): 3F00DF01 (len: 4)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 3F 00 00 .....?..
Received 0 bytes (SW1=62 SW2=84)
card.c:250:sc_transmit_apdu: called
Sending 7 bytes (resp. 258 bytes):
00 A4 00 0C 02 3F 00 .....?.
Received 0 bytes (SW1=90 SW2=00)
card-starcos.c:361:starcos_select_fid: returning with: 0
card.c:759:sc_select_file: returning with: 0
card.c:534:sc_unlock: called
Calling card logout function
card.c:250:sc_transmit_apdu: called
Sending 7 bytes (resp. 258 bytes):
00 A4 00 0C 02 3F 00 .....?.
Received 0 bytes (SW1=90 SW2=00)
sw1 = 0x90, sw2 = 0x00
Binding to PKCS#15, rc=0
0: Detected framework 0. Creating tokens.
Found 1 authentication objects
Found 1 private key
Found 0 public keys
Found 2 certificates
pkcs15-cert.c:115:sc_pkcs15_read_certificate: called
called, path=df01c000, index=2, count=1288
card.c:514:sc_lock: called
called; type=2, path=df01c000
card-starcos.c:375:starcos_select_file: called
current path (path, valid):  (len: 0)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 3F 00 00 .....?..
Received 0 bytes (SW1=62 SW2=84)
card.c:250:sc_transmit_apdu: called
Sending 7 bytes (resp. 258 bytes):
00 A4 00 0C 02 3F 00 .....?.
Received 0 bytes (SW1=90 SW2=00)
card-starcos.c:361:starcos_select_fid: returning with: 0
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 DF 01 00 ........
Received 0 bytes (SW1=62 SW2=84)
card.c:250:sc_transmit_apdu: called
Sending 7 bytes (resp. 258 bytes):
00 A4 00 0C 02 DF 01 .......
Received 0 bytes (SW1=90 SW2=00)
card-starcos.c:361:starcos_select_fid: returning with: 0
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 C0 00 00 ........
Received 9 bytes (SW1=90 SW2=00)
6F 07 80 02 0A 00 82 01 01 o........
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 00 00 01 .....
Received 1 bytes (SW1=90 SW2=00)
08 .
processing FCI bytes
  bytes in file: 2560
  type: working EF
  EF structure: transparent
card-starcos.c:361:starcos_select_fid: returning with: 0
card.c:759:sc_select_file: returning with: 0
called; 1288 bytes at index 2
called; 128 bytes at index 2
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 00 02 80 .....
Received 128 bytes (SW1=90 SW2=00)
30 82 05 04 30 82 03 EC A0 03 02 01 02 02 03 02 0...0...........
E4 70 30 0D 06 09 2A 86 48 86 F7 0D 01 01 05 05 .p0...*.H.......
00 30 81 9D 31 0B 30 09 06 03 55 04 06 13 02 49 .0..1.0...U....I
54 31 18 30 16 06 03 55 04 0A 13 0F 49 6E 66 6F T1.0...U....Info
43 61 6D 65 72 65 20 53 43 70 41 31 14 30 12 06 Camere SCpA1.0..
03 55 04 05 13 0B 30 32 33 31 33 38 32 31 30 30 .U....0231382100
37 31 37 30 35 06 03 55 04 0B 13 2E 43 65 72 74 71705..U....Cert
69 66 69 63 61 74 6F 72 65 20 41 63 63 72 65 64 ificatore Accred
iso7816.c:126:iso7816_read_binary: returning with: 128
card.c:640:sc_read_binary: returning with: 128
called; 128 bytes at index 130
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 00 82 80 .....
Received 128 bytes (SW1=90 SW2=00)
69 74 61 74 6F 20 64 65 6C 20 53 69 73 74 65 6D itato del Sistem
61 20 43 61 6D 65 72 61 6C 65 31 25 30 23 06 03 a Camerale1%0#..
55 04 03 13 1C 49 6E 66 6F 43 61 6D 65 72 65 20 U....InfoCamere
46 69 72 6D 61 20 51 75 61 6C 69 66 69 63 61 74 Firma Qualificat
61 30 1E 17 0D 30 35 30 33 32 33 30 39 35 32 35 a0...05032309525
37 5A 17 0D 30 38 30 33 32 33 30 30 30 30 30 30 7Z..080323000000
5A 30 81 A8 31 0B 30 09 06 03 55 04 06 13 02 49 Z0..1.0...U....I
54 31 17 30 15 06 03 55 04 0A 13 0E 4E 6F 6E 20 T1.0...U....Non
iso7816.c:126:iso7816_read_binary: returning with: 128
card.c:640:sc_read_binary: returning with: 128
called; 128 bytes at index 258
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 01 02 80 .....
Received 128 bytes (SW1=90 SW2=00)
44 69 63 68 69 61 72 61 74 6F 31 1F 30 1D 06 03 Dichiarato1.0...
55 04 0B 13 16 52 41 3D 43 2E 43 2E 49 2E 41 2E U....RA=C.C.I.A.
41 2E 20 44 49 20 50 41 56 49 41 31 36 30 34 06 A. DI PAVIA1604.
03 55 04 03 13 2D 43 41 46 4F 52 49 4F 2F 4C 55 .U...-CAFORIO/LU
49 47 49 2F 43 46 52 4C 47 55 35 38 4C 31 36 42 IGI/CFRLGU58L16B
31 38 30 4C 2F 32 30 30 33 31 31 31 34 38 30 31 180L/20031114801
31 33 31 31 27 30 25 06 03 55 04 0D 13 1E 43 3D 1311'0%..U....C=
43 61 66 6F 72 69 6F 2F 4E 3D 4C 75 69 67 69 2F Caforio/N=Luigi/
iso7816.c:126:iso7816_read_binary: returning with: 128
card.c:640:sc_read_binary: returning with: 128
called; 128 bytes at index 386
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 01 82 80 .....
Received 128 bytes (SW1=90 SW2=00)
44 3D 31 36 2D 30 37 2D 31 39 35 38 30 81 9F 30 D=16-07-19580..0
0D 06 09 2A 86 48 86 F7 0D 01 01 01 05 00 03 81 ...*.H..........
8D 00 30 81 89 02 81 81 00 B5 72 9D D3 2E A8 C2 ..0.......r.....
03 05 C0 E3 8F F6 9C 69 C8 E4 F9 7C 71 B3 5F 59 .......i...|q._Y
C6 60 E6 AF 18 66 AC EC 40 91 59 25 2C DE B8 5A .`...f.. <at> .Y%,..Z
E3 0F 7F 31 5C 00 41 25 67 62 41 F6 EC 31 46 34 ...1\.A%gbA..1F4
9F C0 F3 4A D3 AC 66 64 74 09 DD E8 1B 65 7D A1 ...J..fdt....e}.
65 B3 FD 47 A9 54 1F 5A 79 20 98 F4 F5 EF 7D 6D e..G.T.Zy ....}m
iso7816.c:126:iso7816_read_binary: returning with: 128
card.c:640:sc_read_binary: returning with: 128
called; 128 bytes at index 514
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 02 02 80 .....
Received 128 bytes (SW1=90 SW2=00)
D8 F4 0E A2 37 12 D2 C5 E3 B6 8C 15 74 B4 F9 D0 ....7.......t...
A4 4E 91 B6 C0 95 A2 59 9D B2 2A 41 07 9E 09 70 .N.....Y..*A...p
DE 06 18 6A A9 0B 3C CB 23 02 03 01 00 01 A3 82 ...j..<.#.......
01 C2 30 82 01 BE 30 50 06 03 55 1D 20 04 49 30 ..0...0P..U. .I0
47 30 45 06 06 2B 4C 0E 01 01 01 30 3B 30 39 06 G0E..+L....0;09.
08 2B 06 01 05 05 07 02 01 16 2D 68 74 74 70 3A .+........-http:
2F 2F 77 77 77 2E 63 61 72 64 2E 69 6E 66 6F 63 //www.card.infoc
61 6D 65 72 65 2E 69 74 2F 64 6F 63 2F 6D 61 6E amere.it/doc/man
iso7816.c:126:iso7816_read_binary: returning with: 128
card.c:640:sc_read_binary: returning with: 128
called; 128 bytes at index 642
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 02 82 80 .....
Received 128 bytes (SW1=90 SW2=00)
75 61 6C 69 2E 68 74 6D 30 18 06 08 2B 06 01 05 uali.htm0...+...
05 07 01 03 04 0C 30 0A 30 08 06 06 04 00 8E 46 ......0.0......F
01 01 30 0E 06 03 55 1D 0F 01 01 FF 04 04 03 02 ..0...U.........
06 40 30 27 06 03 55 1D 12 04 20 30 1E 81 1C 66 . <at> 0'..U... 0...f
69 72 6D 61 2E 64 69 67 69 74 61 6C 65 40 69 6E irma.digitale <at> in
66 6F 63 61 6D 65 72 65 2E 69 74 30 1F 06 03 55 focamere.it0...U
1D 23 04 18 30 16 80 14 66 5D 69 C7 E5 E2 50 DC .#..0...f]i...P.
5E 69 E4 4E 4E 6E 44 59 96 91 DB 6B 30 81 D6 06 ^i.NNnDY...k0...
iso7816.c:126:iso7816_read_binary: returning with: 128
card.c:640:sc_read_binary: returning with: 128
called; 128 bytes at index 770
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 03 02 80 .....
Received 128 bytes (SW1=90 SW2=00)
03 55 1D 1F 04 81 CE 30 81 CB 30 81 C8 A0 81 C5 .U.....0..0.....
A0 81 C2 86 81 BF 6C 64 61 70 3A 2F 2F 6C 64 61 ......ldap://lda
70 32 2E 69 6E 66 6F 63 61 6D 65 72 65 2E 69 74 p2.infocamere.it
3A 33 38 39 2F 63 6E 25 33 64 49 6E 66 6F 43 61 :389/cn%3dInfoCa
6D 65 72 65 25 32 30 46 69 72 6D 61 25 32 30 51 mere%20Firma%20Q
75 61 6C 69 66 69 63 61 74 61 25 32 30 43 52 4C ualificata%20CRL
30 31 2C 6F 75 25 33 64 43 65 72 74 69 66 69 63 01,ou%3dCertific
61 74 6F 72 65 25 32 30 41 63 63 72 65 64 69 74 atore%20Accredit
iso7816.c:126:iso7816_read_binary: returning with: 128
card.c:640:sc_read_binary: returning with: 128
called; 128 bytes at index 898
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 03 82 80 .....
Received 128 bytes (SW1=90 SW2=00)
61 74 6F 25 32 30 64 65 6C 25 32 30 53 69 73 74 ato%20del%20Sist
65 6D 61 25 32 30 43 61 6D 65 72 61 6C 65 2C 6F ema%20Camerale,o
25 33 64 49 6E 66 6F 43 61 6D 65 72 65 25 32 30 %3dInfoCamere%20
53 43 70 41 2C 63 25 33 64 49 54 3F 63 65 72 74 SCpA,c%3dIT?cert
69 66 69 63 61 74 65 52 65 76 6F 63 61 74 69 6F ificateRevocatio
6E 4C 69 73 74 30 1D 06 03 55 1D 0E 04 16 04 14 nList0...U......
99 7A 2C 35 B7 38 36 AC 71 5E A9 FE 43 8D 8E D6 .z,5.86.q^..C...
BB 24 CD A3 30 0D 06 09 2A 86 48 86 F7 0D 01 01 .$..0...*.H.....
iso7816.c:126:iso7816_read_binary: returning with: 128
card.c:640:sc_read_binary: returning with: 128
called; 128 bytes at index 1026
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 04 02 80 .....
Received 128 bytes (SW1=90 SW2=00)
05 05 00 03 82 01 01 00 4B 2F 12 58 9B 72 EF 83 ........K/.X.r..
D5 A7 18 CF B2 B8 37 C1 EA 2D 29 09 22 95 00 2F ......7..-)."../
18 6C 39 33 FC 9F 4A DE 4E B7 A5 2D 41 89 1B F0 .l93..J.N..-A...
68 57 2A 51 E0 D3 FE B8 88 6B 38 0B E1 DD A6 76 hW*Q.....k8....v
E9 AE 7E 3C 0B F6 57 35 E3 E3 C7 02 A7 2F 79 69 ..~<..W5...../yi
BC 8C 7F 0B DA FB 03 5A 6B D9 6B AD F8 DD 66 08 .......Zk.k...f.
02 9B 83 DD 48 F8 6A 9A FC 7B 83 E1 BB 91 D0 66 ....H.j..{.....f
AD 30 28 CB A5 53 E3 92 95 82 30 B7 D0 83 36 BA .0(..S....0...6.
iso7816.c:126:iso7816_read_binary: returning with: 128
card.c:640:sc_read_binary: returning with: 128
called; 128 bytes at index 1154
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 04 82 80 .....
Received 128 bytes (SW1=90 SW2=00)
A0 4D AA E7 10 AF 62 33 07 D0 5A 83 29 07 7F 97 .M....b3..Z.)...
A2 B4 80 D7 3E 3C 02 29 6B E3 99 3D F3 59 E6 B4 ....><.)k..=.Y..
25 88 4A 03 B9 AE 61 FE 5B 72 43 ED 92 43 C0 71 %.J...a.[rC..C.q
41 73 F2 99 88 E8 9B 64 2D DF 3F 72 C5 94 29 DE As.....d-.?r..).
1C C0 06 37 B9 44 FE 92 82 D1 A5 7D 25 84 91 A7 ...7.D.....}%...
A8 E3 A9 7E 9B DC A7 F8 5A 20 72 46 33 0A 2C F1 ...~....Z rF3.,.
B1 5E 29 AB 4C 34 81 BF EB A8 43 54 47 46 33 E9 .^).L4....CTGF3.
71 86 EA AA AB 9B 3F 32 2C 7D C0 58 CD 63 AA 94 q.....?2,}.X.c..
iso7816.c:126:iso7816_read_binary: returning with: 128
card.c:640:sc_read_binary: returning with: 128
called; 8 bytes at index 1282
card.c:250:sc_transmit_apdu: called
Sending 5 bytes (resp. 258 bytes):
00 B0 05 02 08 .....
Received 8 bytes (SW1=90 SW2=00)
E3 3A 1C 53 FE E3 0E 27 .:.S...'
iso7816.c:126:iso7816_read_binary: returning with: 8
card.c:640:sc_read_binary: returning with: 8
card.c:637:sc_read_binary: returning with: 1288
card.c:534:sc_unlock: called
Calling card logout function
card.c:250:sc_transmit_apdu: called
Sending 7 bytes (resp. 258 bytes):
00 A4 00 0C 02 3F 00 .....?.
Received 0 bytes (SW1=90 SW2=00)
sw1 = 0x90, sw2 = 0x00
called, left=1284, depth 0
Looking for 'tbsCertificate', tag 0x1000010
decoding 'tbsCertificate'
 called, left=1004, depth 1
Looking for 'version', tag 0x21000000, OPTIONAL
 decoding 'version'
  called, left=3, depth 2
Looking for 'version', tag 0x2
  decoding 'version'
asn1.c:1102:asn1_decode: returning with: 0
Looking for 'serialNumber', tag 0x2
 decoding 'serialNumber'
Looking for 'signature', tag 0x1000010
 decoding 'signature'
Looking for 'issuer', tag 0x1000010
 decoding 'issuer'
Looking for 'validity', tag 0x1000010
 decoding 'validity'
Looking for 'subject', tag 0x1000010
 decoding 'subject'
Looking for 'subjectPublicKeyInfo', tag 0x1000010
 decoding 'subjectPublicKeyInfo'
  called, left=159, depth 2
Looking for 'algorithm', tag 0x1000010
  decoding 'algorithm'
   called, left=13, depth 3
Looking for 'algorithm', tag 0x6
   decoding 'algorithm'
Looking for 'nullParam', tag 0x5, OPTIONAL
   decoding 'nullParam'
asn1.c:1102:asn1_decode: returning with: 0
Looking for 'subjectPublicKey', tag 0x3
  decoding 'subjectPublicKey'
asn1.c:1102:asn1_decode: returning with: 0
Looking for 'extensions', tag 0x21000003, OPTIONAL
 decoding 'extensions'
  called, left=450, depth 2
Looking for 'x509v3', tag 0x1000010, OPTIONAL
  decoding 'x509v3'
   called, left=446, depth 3
Looking for 'certificatePolicies', tag 0x1000010, OPTIONAL
   decoding 'certificatePolicies'
Looking for 'subjectKeyIdentifier', tag 0x1000010, OPTIONAL
   decoding 'subjectKeyIdentifier'
Looking for 'crlDistributionPoints', tag 0x1000010, OPTIONAL
   decoding 'crlDistributionPoints'
Looking for 'authorityKeyIdentifier', tag 0x1000010, OPTIONAL
   decoding 'authorityKeyIdentifier'
Looking for 'keyUsage', tag 0x1000010, OPTIONAL
   decoding 'keyUsage'
asn1.c:1102:asn1_decode: returning with: 0
asn1.c:1102:asn1_decode: returning with: 0
asn1.c:1102:asn1_decode: returning with: 0
Looking for 'signatureAlgorithm', tag 0x1000010
decoding 'signatureAlgorithm'
 called, left=13, depth 1
Looking for 'algorithm', tag 0x6
 decoding 'algorithm'
Looking for 'nullParam', tag 0x5, OPTIONAL
 decoding 'nullParam'
asn1.c:1102:asn1_decode: returning with: 0
Looking for 'signatureValue', tag 0x3
decoding 'signatureValue'
asn1.c:1102:asn1_decode: returning with: 0
called, left=140, depth 0
Looking for 'publicKeyCoefficients', tag 0x1000010
decoding 'publicKeyCoefficients'
 called, left=137, depth 1
Looking for 'modulus', tag 0x2
 decoding 'modulus'
Looking for 'exponent', tag 0x2
 decoding 'exponent'
asn1.c:1102:asn1_decode: returning with: 0
asn1.c:1102:asn1_decode: returning with: 0
pkcs15-cert.c:115:sc_pkcs15_read_certificate: called
called, path=df01c008, index=2, count=0
card.c:514:sc_lock: called
called; type=2, path=df01c008
card-starcos.c:375:starcos_select_file: called
current path (path, valid):  (len: 0)
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 3F 00 00 .....?..
Received 0 bytes (SW1=62 SW2=84)
card.c:250:sc_transmit_apdu: called
Sending 7 bytes (resp. 258 bytes):
00 A4 00 0C 02 3F 00 .....?.
Received 0 bytes (SW1=90 SW2=00)
card-starcos.c:361:starcos_select_fid: returning with: 0
card.c:250:sc_transmit_apdu: called
Sending 8 bytes (resp. 258 bytes):
00 A4 00 00 02 DF 01 00 ........
Received 0 bytes (SW1=62 SW2=84)
card.c:250:sc_transmit_apdu: called
**************************************************************
 
 
<div>
<div>Hi 
all,<br>finally I succesfully installed SCB (scb-0.5-pre1e.exe).</div>
<div>&nbsp;</div>
<div>Anyway my problem with InfoCamere 
1202 card (STARCOS 2.3) remains.</div>
<div>&nbsp;</div>
<div>Now, I try to list all necessary 
elements (3 commands) to analize this problem.</div>
<div>
<br>NOTE: I tested card with InfoCamere owner 
product<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (Dike) <a href="http://www.card.infocamere.it/software/software_home.htm">http://www.card.infocamere.it/software/software_home.htm</a><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
and all seems to run correctly.</div>
<div>&nbsp;</div>
<div>If someone needs further specific 
elements, please let me know.<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<br>Thanks in advance at all.</div>
<div>&nbsp;</div>
<div>First element 
*********************************************************<br>DUMP COMMAND RESULT 
+ RELATIVE ERRORS LOG<br>C:\Programmi\Smart card bundle&gt;p15dump.exe<br>Using 
libopensc version 0.9.4.<br>Card detected in reader 'CASTLES EZ100PU 
0'<br>Connecting... connected.<br>ATR = 
3b:b7:94:00:81:31:fe:65:53:50:4b:32:33:90:00:d1<br>Looking for a PKCS#15 
compatible Smart Card... found.<br>PKCS#15 Card [Infocamere 1202 
Card]:<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
Version&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; : 
0<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Serial number&nbsp; : 
d2760000012590154800131c13<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
Manufacturer ID: Infocamere<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
Flags&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; :</div>
<div>Enumerating PIN codes... 1 
found.<br>PIN [Non-repudiation 
PIN]<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Com. Flags&nbsp; : private, 
modifiable<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Auth 
ID&nbsp;&nbsp;&nbsp;&nbsp; : 02<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
Flags&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; : [0x31], case-sensitive, initialized, 
needs-padding<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
Length&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; : min_len:5, max_len:8, 
stored_len:8<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Pad 
char&nbsp;&nbsp;&nbsp; : 0x00<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
Reference&nbsp;&nbsp; : 153<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
Encoding&nbsp;&nbsp;&nbsp; : 
ASCII-numeric<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
Path&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; : 
3F00DF01<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Tries left&nbsp; : 
3</div>
<div>Enumerating Private keys... 1 
found.<br>Private RSA key [Non repudiation 
Key]<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Com. Flags&nbsp; : 
private<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Com. Auth ID: 
02<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
Usage&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; : [0x200], 
nonRepudiation<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Access Flags: 
[0x1D], sensitive, alwaysSensitive, neverExtract, 
local<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ModLength&nbsp;&nbsp; : 
1024<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Key 
ref&nbsp;&nbsp;&nbsp;&nbsp; : 132<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
Native&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; : 
yes<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
Path&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; : 
3F00DF01<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
ID&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; : 02</div>
<div>Enumerating Public keys... none 
found.</div>
<div>Enumerating X.509 certificates... 2 
found.<br>X.509 Certificate [User Non-repudiation 
Certificate]<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Com. Flags&nbsp; : 
modifiable<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Authority&nbsp;&nbsp; : 
no<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
Path&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; : 
df01c000<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
ID&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; : 02<br>X.509 
Certificate [CA Certificate]<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Com. 
Flags&nbsp; : modifiable<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
Authority&nbsp;&nbsp; : yes<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
Path&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; : 
df01c008<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
ID&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; : 03</div>
<div>Enumerating data objects... none 
found.</div>
<div>&nbsp;</div>
<div>opensc-errors.log:</div>
<div>&nbsp;</div>
<div>File not 
found<br>card-starcos.c:317:starcos_select_fid: returning with: File not 
found<br>card.c:759:sc_select_file: returning with: File not 
found<br>***********************************************************************≤/div>
<div>&nbsp;</div>
<div>Second element 
********************************************************≤br>TRY TO READ 
CERTIFICATE WITH ID 03 + RELATIVE DEBUG &amp; ERRORS LOG</div>
<div>C:\Programmi\Smart card 
bundle&gt;pkcs15-tool.exe --read-certificate 03<br>Certificate read failed: 
Invalid ASN.1 object</div>
<div>&nbsp;</div>
<div>opensc-errors.log:</div>
<div>&nbsp;</div>
<div>File not 
found<br>card-starcos.c:317:starcos_select_fid: returning with: File not 
found<br>card.c:759:sc_select_file: returning with: File not found<br>X.509 
certificate not found</div>
<div>&nbsp;</div>
<div>opensc-debug.log: (I omitted 
pre-card-matching debug)</div>
<div>&nbsp;</div>
<div>opensc version: 
0.9.4<br>sc.c:142:sc_detect_card_presence: 
called<br>sc.c:147:sc_detect_card_presence: returning with: 
1<br>card.c:368:sc_connect_card: called<br>ATR&nbsp;&nbsp;&nbsp;&nbsp; : 
3b:b7:94:00:81:31:fe:65:53:50:4b:32:33:90:00:d1<br>ATR try : 
3b:6e:00:ff:45:73:74:45:49:44:20:76:65:72:20:31:2e:30<br>ATR try : 
3b:fe:94:00:ff:80:b1:fa:45:1f:03:45:73:74:45:49:44:20:76:65:72:20:31:2e:30:43<br>matching 
configured ATRs<br>matching built-in ATRs<br>... omitted ...<br>trying driver: 
starcos<br>ATR&nbsp;&nbsp;&nbsp;&nbsp; : 
3b:b7:94:00:81:31:fe:65:53:50:4b:32:33:90:00:d1<br>ATR try : 
3B:B7:94:00:c0:24:31:fe:65:53:50:4b:32:33:90:00:b4<br>ATR try : 
3B:B7:94:00:81:31:fe:65:53:50:4b:32:33:90:00:d1<br>matched: STARCOS SPK 
2.3<br>card info: STARCOS SPK 2.3, 7001, 0x0<br>card.c:477:sc_connect_card: 
returning with: 0<br>card.c:514:sc_lock: called<br>pkcs15.c:611:sc_pkcs15_bind: 
called<br>trying normal pkcs15 processing<br>called; type=2, 
path=3f002f00<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid):&nbsp; (len: 0)<br>card.c:250:sc_transmit_apdu: called<br>Sending 
8 bytes (resp. 258 bytes):<br>00 A4 00 00 02 3F 00 00 .....?..<br>Received 0 
bytes (SW1=62 SW2=84)<br>card.c:250:sc_transmit_apdu: called<br>Sending 7 bytes 
(resp. 258 bytes):<br>00 A4 00 0C 02 3F 00 .....?.<br>Received 0 bytes (SW1=90 
SW2=00)<br>card-starcos.c:361:starcos_select_fid: returning with: 
0<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 bytes (resp. 258 
bytes):<br>00 A4 00 00 02 2F 00 00 ...../..<br>Received 0 bytes (SW1=6A 
SW2=82)<br>sw1 = 0x6a, sw2 = 0x82<br>File not 
found<br>card-starcos.c:317:starcos_select_fid: returning with: 
-1201<br>card.c:759:sc_select_file: returning with: -1201<br>called; type=2, 
path=3f005015<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid): 3F00 (len: 2)<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 
bytes (resp. 258 bytes):<br>00 A4 00 00 02 50 15 00 .....P..<br>Received 0 bytes 
(SW1=6A SW2=82)<br>sw1 = 0x6a, sw2 = 0x82<br>File not 
found<br>card-starcos.c:317:starcos_select_fid: returning with: 
-1201<br>card.c:759:sc_select_file: returning with: -1201<br>called; type=2, 
path=3f005031<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid): 3F00 (len: 2)<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 
bytes (resp. 258 bytes):<br>00 A4 00 00 02 50 31 00 .....P1.<br>Received 0 bytes 
(SW1=6A SW2=82)<br>sw1 = 0x6a, sw2 = 
0x82<br>pkcs15-syn.c:85:sc_pkcs15_bind_synthetic: called<br>use builtin 
drivers<br>trying esteid<br>trying openpgp<br>trying tcos<br>trying 
starcert<br>called; type=2, 
path=3f00fe13<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid): 3F00 (len: 2)<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 
bytes (resp. 258 bytes):<br>00 A4 00 00 02 FE 13 00 ........<br>Received 0 bytes 
(SW1=6A SW2=82)<br>sw1 = 0x6a, sw2 = 0x82<br>File not 
found<br>card-starcos.c:317:starcos_select_fid: returning with: 
-1201<br>card.c:759:sc_select_file: returning with: -1201<br>trying 
infocamere<br>called; type=2, 
path=3f002f02<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid): 3F00 (len: 2)<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 
bytes (resp. 258 bytes):<br>00 A4 00 00 02 2F 02 00 ...../..<br>Received 9 bytes 
(SW1=90 SW2=00)<br>6F 07 80 02 00 1A 82 01 01 
o........<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 00 00 01 .....<br>Received 1 bytes (SW1=90 SW2=00)<br>5A 
Z<br>processing FCI bytes<br>&nbsp; bytes in file: 26<br>&nbsp; type: working 
EF<br>&nbsp; EF structure: transparent<br>card-starcos.c:361:starcos_select_fid: 
returning with: 0<br>card.c:759:sc_select_file: returning with: 0<br>called; 26 
bytes at index 0<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes 
(resp. 258 bytes):<br>00 B0 00 00 1A .....<br>Received 26 bytes (SW1=90 
SW2=00)<br>5A 0D D2 76 00 00 01 25 90 15 48 00 13 1C 13 5F 
Z..v...%..H...._<br>20 08 12 02 05 00 00 77 78 
25&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
......wx%<br>iso7816.c:126:iso7816_read_binary: returning with: 
26<br>card.c:640:sc_read_binary: returning with: 26<br>called; type=2, 
path=11111a02<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid): 3F00 (len: 2)<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 
bytes (resp. 258 bytes):<br>00 A4 00 00 02 11 11 00 ........<br>Received 0 bytes 
(SW1=62 SW2=84)<br>card.c:250:sc_transmit_apdu: called<br>Sending 7 bytes (resp. 
258 bytes):<br>00 A4 00 0C 02 11 11 .......<br>Received 0 bytes (SW1=90 
SW2=00)<br>card-starcos.c:361:starcos_select_fid: returning with: 
0<br>card-starcos.c:375:starcos_select_file: called<br>current path (path, 
valid): 3F001111 (len: 4)<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 
bytes (resp. 258 bytes):<br>00 A4 00 00 02 1A 02 00 ........<br>Received 0 bytes 
(SW1=6A SW2=82)<br>sw1 = 0x6a, sw2 = 0x82<br>File not 
found<br>card-starcos.c:317:starcos_select_fid: returning with: 
-1201<br>card.c:759:sc_select_file: returning with: -1201<br>called; type=2, 
path=df01c000<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid): 3F001111 (len: 4)<br>card.c:250:sc_transmit_apdu: 
called<br>Sending 8 bytes (resp. 258 bytes):<br>00 A4 00 00 02 DF 01 00 
........<br>Received 0 bytes (SW1=62 SW2=84)<br>card.c:250:sc_transmit_apdu: 
called<br>Sending 7 bytes (resp. 258 bytes):<br>00 A4 00 0C 02 DF 01 
.......<br>Received 0 bytes (SW1=90 
SW2=00)<br>card-starcos.c:361:starcos_select_fid: returning with: 
0<br>card-starcos.c:375:starcos_select_file: called<br>current path (path, 
valid): 3F00DF01 (len: 4)<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 
bytes (resp. 258 bytes):<br>00 A4 00 00 02 C0 00 00 ........<br>Received 9 bytes 
(SW1=90 SW2=00)<br>6F 07 80 02 0A 00 82 01 01 
o........<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 00 00 01 .....<br>Received 1 bytes (SW1=90 SW2=00)<br>08 
.<br>card-starcos.c:361:starcos_select_fid: returning with: 
0<br>card.c:759:sc_select_file: returning with: 0<br>called; 2 bytes at index 
0<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 00 00 02 .....<br>Received 2 bytes (SW1=90 SW2=00)<br>08 05 
..<br>iso7816.c:126:iso7816_read_binary: returning with: 
2<br>card.c:640:sc_read_binary: returning with: 2<br>called; type=2, 
path=df01c008<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid): 3F00DF01 (len: 4)<br>card.c:250:sc_transmit_apdu: 
called<br>Sending 8 bytes (resp. 258 bytes):<br>00 A4 00 00 02 C0 08 00 
........<br>Received 9 bytes (SW1=90 SW2=00)<br>6F 07 80 02 06 00 82 01 01 
o........<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 00 00 01 .....<br>Received 1 bytes (SW1=90 SW2=00)<br>00 
.<br>card-starcos.c:361:starcos_select_fid: returning with: 
0<br>card.c:759:sc_select_file: returning with: 0<br>called; 2 bytes at index 
0<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 00 00 02 .....<br>Received 2 bytes (SW1=90 SW2=00)<br>00 00 
..<br>iso7816.c:126:iso7816_read_binary: returning with: 
2<br>card.c:640:sc_read_binary: returning with: 2<br>called; type=2, 
path=3f00<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid): 3F00DF01 (len: 4)<br>card.c:250:sc_transmit_apdu: 
called<br>Sending 8 bytes (resp. 258 bytes):<br>00 A4 00 00 02 3F 00 00 
.....?..<br>Received 0 bytes (SW1=62 SW2=84)<br>card.c:250:sc_transmit_apdu: 
called<br>Sending 7 bytes (resp. 258 bytes):<br>00 A4 00 0C 02 3F 00 
.....?.<br>Received 0 bytes (SW1=90 
SW2=00)<br>card-starcos.c:361:starcos_select_fid: returning with: 
0<br>card.c:759:sc_select_file: returning with: 
0<br>pkcs15-cert.c:115:sc_pkcs15_read_certificate: called<br>called, 
path=df01c008, index=2, count=0<br>called; type=2, 
path=df01c008<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid): 3F00 (len: 2)<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 
bytes (resp. 258 bytes):<br>00 A4 00 00 02 DF 01 00 ........<br>Received 0 bytes 
(SW1=62 SW2=84)<br>card.c:250:sc_transmit_apdu: called<br>Sending 7 bytes (resp. 
258 bytes):<br>00 A4 00 0C 02 DF 01 .......<br>Received 0 bytes (SW1=90 
SW2=00)<br>card-starcos.c:361:starcos_select_fid: returning with: 
0<br>card-starcos.c:375:starcos_select_file: called<br>current path (path, 
valid): 3F00DF01 (len: 4)<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 
bytes (resp. 258 bytes):<br>00 A4 00 00 02 C0 08 00 ........<br>Received 9 bytes 
(SW1=90 SW2=00)<br>6F 07 80 02 06 00 82 01 01 
o........<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 00 00 01 .....<br>Received 1 bytes (SW1=90 SW2=00)<br>00 
.<br>processing FCI bytes<br>&nbsp; bytes in file: 1536<br>&nbsp; type: working 
EF<br>&nbsp; EF structure: transparent<br>card-starcos.c:361:starcos_select_fid: 
returning with: 0<br>card.c:759:sc_select_file: returning with: 0<br>called; 0 
bytes at index 2<br>pkcs15.c:686:sc_pkcs15_unbind: 
called<br>card.c:534:sc_unlock: called<br>Calling card logout 
function<br>card.c:250:sc_transmit_apdu: called<br>Sending 7 bytes (resp. 258 
bytes):<br>00 A4 00 0C 02 3F 00 .....?.<br>Received 0 bytes (SW1=90 
SW2=00)<br>sw1 = 0x90, sw2 = 0x00<br>card.c:489:sc_disconnect_card: 
called<br>card.c:504:sc_disconnect_card: returning with: 
0<br>ctx.c:709:sc_release_context: 
called<br>***********************************************************************≤/div>
<div>&nbsp;</div>
<div>Third element 
*********************************************************<br>PKCS11 TEST COMMAND 
+ RELATIVE DEBUG &amp; ERRORS LOG<br>C:\Programmi\Smart card 
bundle&gt;pkcs11-tool.exe --login --test<br>Please enter User 
PIN:<br>C_SeedRandom() and C_GenerateRandom():<br>&nbsp; not 
implemented<br>Digests:<br>&nbsp; all 4 digest functions seem to work<br>&nbsp; 
MD5: OK<br>&nbsp; SHA-1: OK<br>&nbsp; RIPEMD160: OK<br>Signatures (currently 
only RSA signatures)<br>&nbsp; testing key 0 (Non repudiation Key)<br>error: 
PKCS11 function C_SignFinal failed: rv = CKR_GENERAL_ERROR (0x5)</div>
<div>Aborting.</div>
<div>&nbsp;</div>
<div>opensc-errors.log:</div>
<div>&nbsp;</div>
<div>File not 
found<br>card-starcos.c:317:starcos_select_fid: returning with: File not 
found<br>card.c:759:sc_select_file: returning with: File not found<br>X.509 
certificate not found<br>Conditions of use not 
satisfied<br>card-starcos.c:1152:starcos_set_security_env: returning with: Not 
allowed<br>sec.c:67:sc_set_security_env: returning with: Not 
allowed<br>pkcs15-sec.c:312:sc_pkcs15_compute_signature: sc_set_security_env() 
failed: Not allowed</div>
<div>&nbsp;</div>
<div>opensc-debug.log: (I omitted 
pre-card-matching debug)</div>
<div>&nbsp;</div>
<div>opensc version: 0.9.4<br>0: Detecting 
smart card<br>sc.c:142:sc_detect_card_presence: 
called<br>sc.c:147:sc_detect_card_presence: returning with: 1<br>0: Connecting 
to smart card<br>card.c:368:sc_connect_card: 
called<br>ATR&nbsp;&nbsp;&nbsp;&nbsp; : 
3b:b7:94:00:81:31:fe:65:53:50:4b:32:33:90:00:d1<br>ATR try : 
3b:6e:00:ff:45:73:74:45:49:44:20:76:65:72:20:31:2e:30<br>ATR try : 
3b:fe:94:00:ff:80:b1:fa:45:1f:03:45:73:74:45:49:44:20:76:65:72:20:31:2e:30:43<br>matching 
configured ATRs<br>matching built-in ATRs<br>... omitted ...<br>trying driver: 
starcos<br>ATR&nbsp;&nbsp;&nbsp;&nbsp; : 
3b:b7:94:00:81:31:fe:65:53:50:4b:32:33:90:00:d1<br>ATR try : 
3B:B7:94:00:c0:24:31:fe:65:53:50:4b:32:33:90:00:b4<br>ATR try : 
3B:B7:94:00:81:31:fe:65:53:50:4b:32:33:90:00:d1<br>matched: STARCOS SPK 
2.3<br>card info: STARCOS SPK 2.3, 7001, 0x0<br>card.c:477:sc_connect_card: 
returning with: 0<br>0: Detecting Framework<br>pkcs15.c:611:sc_pkcs15_bind: 
called<br>card.c:514:sc_lock: called<br>trying normal pkcs15 
processing<br>called; type=2, 
path=3f002f00<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid):&nbsp; (len: 0)<br>card.c:250:sc_transmit_apdu: called<br>Sending 
8 bytes (resp. 258 bytes):<br>00 A4 00 00 02 3F 00 00 .....?..<br>Received 0 
bytes (SW1=62 SW2=84)<br>card.c:250:sc_transmit_apdu: called<br>Sending 7 bytes 
(resp. 258 bytes):<br>00 A4 00 0C 02 3F 00 .....?.<br>Received 0 bytes (SW1=90 
SW2=00)<br>card-starcos.c:361:starcos_select_fid: returning with: 
0<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 bytes (resp. 258 
bytes):<br>00 A4 00 00 02 2F 00 00 ...../..<br>Received 0 bytes (SW1=6A 
SW2=82)<br>sw1 = 0x6a, sw2 = 0x82<br>File not 
found<br>card-starcos.c:317:starcos_select_fid: returning with: 
-1201<br>card.c:759:sc_select_file: returning with: -1201<br>called; type=2, 
path=3f005015<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid): 3F00 (len: 2)<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 
bytes (resp. 258 bytes):<br>00 A4 00 00 02 50 15 00 .....P..<br>Received 0 bytes 
(SW1=6A SW2=82)<br>sw1 = 0x6a, sw2 = 0x82<br>File not 
found<br>card-starcos.c:317:starcos_select_fid: returning with: 
-1201<br>card.c:759:sc_select_file: returning with: -1201<br>called; type=2, 
path=3f005031<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid): 3F00 (len: 2)<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 
bytes (resp. 258 bytes):<br>00 A4 00 00 02 50 31 00 .....P1.<br>Received 0 bytes 
(SW1=6A SW2=82)<br>sw1 = 0x6a, sw2 = 
0x82<br>pkcs15-syn.c:85:sc_pkcs15_bind_synthetic: called<br>use builtin 
drivers<br>trying esteid<br>trying openpgp<br>trying tcos<br>trying 
starcert<br>called; type=2, 
path=3f00fe13<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid): 3F00 (len: 2)<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 
bytes (resp. 258 bytes):<br>00 A4 00 00 02 FE 13 00 ........<br>Received 0 bytes 
(SW1=6A SW2=82)<br>sw1 = 0x6a, sw2 = 0x82<br>File not 
found<br>card-starcos.c:317:starcos_select_fid: returning with: 
-1201<br>card.c:759:sc_select_file: returning with: -1201<br>trying 
infocamere<br>called; type=2, 
path=3f002f02<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid): 3F00 (len: 2)<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 
bytes (resp. 258 bytes):<br>00 A4 00 00 02 2F 02 00 ...../..<br>Received 9 bytes 
(SW1=90 SW2=00)<br>6F 07 80 02 00 1A 82 01 01 
o........<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 00 00 01 .....<br>Received 1 bytes (SW1=90 SW2=00)<br>5A 
Z<br>processing FCI bytes<br>&nbsp; bytes in file: 26<br>&nbsp; type: working 
EF<br>&nbsp; EF structure: transparent<br>card-starcos.c:361:starcos_select_fid: 
returning with: 0<br>card.c:759:sc_select_file: returning with: 0<br>called; 26 
bytes at index 0<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes 
(resp. 258 bytes):<br>00 B0 00 00 1A .....<br>Received 26 bytes (SW1=90 
SW2=00)<br>5A 0D D2 76 00 00 01 25 90 15 48 00 13 1C 13 5F 
Z..v...%..H...._<br>20 08 12 02 05 00 00 77 78 
25&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
......wx%<br>iso7816.c:126:iso7816_read_binary: returning with: 
26<br>card.c:640:sc_read_binary: returning with: 26<br>called; type=2, 
path=11111a02<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid): 3F00 (len: 2)<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 
bytes (resp. 258 bytes):<br>00 A4 00 00 02 11 11 00 ........<br>Received 0 bytes 
(SW1=62 SW2=84)<br>card.c:250:sc_transmit_apdu: called<br>Sending 7 bytes (resp. 
258 bytes):<br>00 A4 00 0C 02 11 11 .......<br>Received 0 bytes (SW1=90 
SW2=00)<br>card-starcos.c:361:starcos_select_fid: returning with: 
0<br>card-starcos.c:375:starcos_select_file: called<br>current path (path, 
valid): 3F001111 (len: 4)<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 
bytes (resp. 258 bytes):<br>00 A4 00 00 02 1A 02 00 ........<br>Received 0 bytes 
(SW1=6A SW2=82)<br>sw1 = 0x6a, sw2 = 0x82<br>File not 
found<br>card-starcos.c:317:starcos_select_fid: returning with: 
-1201<br>card.c:759:sc_select_file: returning with: -1201<br>called; type=2, 
path=df01c000<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid): 3F001111 (len: 4)<br>card.c:250:sc_transmit_apdu: 
called<br>Sending 8 bytes (resp. 258 bytes):<br>00 A4 00 00 02 DF 01 00 
........<br>Received 0 bytes (SW1=62 SW2=84)<br>card.c:250:sc_transmit_apdu: 
called<br>Sending 7 bytes (resp. 258 bytes):<br>00 A4 00 0C 02 DF 01 
.......<br>Received 0 bytes (SW1=90 
SW2=00)<br>card-starcos.c:361:starcos_select_fid: returning with: 
0<br>card-starcos.c:375:starcos_select_file: called<br>current path (path, 
valid): 3F00DF01 (len: 4)<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 
bytes (resp. 258 bytes):<br>00 A4 00 00 02 C0 00 00 ........<br>Received 9 bytes 
(SW1=90 SW2=00)<br>6F 07 80 02 0A 00 82 01 01 
o........<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 00 00 01 .....<br>Received 1 bytes (SW1=90 SW2=00)<br>08 
.<br>card-starcos.c:361:starcos_select_fid: returning with: 
0<br>card.c:759:sc_select_file: returning with: 0<br>called; 2 bytes at index 
0<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 00 00 02 .....<br>Received 2 bytes (SW1=90 SW2=00)<br>08 05 
..<br>iso7816.c:126:iso7816_read_binary: returning with: 
2<br>card.c:640:sc_read_binary: returning with: 2<br>called; type=2, 
path=df01c008<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid): 3F00DF01 (len: 4)<br>card.c:250:sc_transmit_apdu: 
called<br>Sending 8 bytes (resp. 258 bytes):<br>00 A4 00 00 02 C0 08 00 
........<br>Received 9 bytes (SW1=90 SW2=00)<br>6F 07 80 02 06 00 82 01 01 
o........<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 00 00 01 .....<br>Received 1 bytes (SW1=90 SW2=00)<br>00 
.<br>card-starcos.c:361:starcos_select_fid: returning with: 
0<br>card.c:759:sc_select_file: returning with: 0<br>called; 2 bytes at index 
0<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 00 00 02 .....<br>Received 2 bytes (SW1=90 SW2=00)<br>00 00 
..<br>iso7816.c:126:iso7816_read_binary: returning with: 
2<br>card.c:640:sc_read_binary: returning with: 2<br>called; type=2, 
path=3f00<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid): 3F00DF01 (len: 4)<br>card.c:250:sc_transmit_apdu: 
called<br>Sending 8 bytes (resp. 258 bytes):<br>00 A4 00 00 02 3F 00 00 
.....?..<br>Received 0 bytes (SW1=62 SW2=84)<br>card.c:250:sc_transmit_apdu: 
called<br>Sending 7 bytes (resp. 258 bytes):<br>00 A4 00 0C 02 3F 00 
.....?.<br>Received 0 bytes (SW1=90 
SW2=00)<br>card-starcos.c:361:starcos_select_fid: returning with: 
0<br>card.c:759:sc_select_file: returning with: 0<br>card.c:534:sc_unlock: 
called<br>Calling card logout function<br>card.c:250:sc_transmit_apdu: 
called<br>Sending 7 bytes (resp. 258 bytes):<br>00 A4 00 0C 02 3F 00 
.....?.<br>Received 0 bytes (SW1=90 SW2=00)<br>sw1 = 0x90, sw2 = 0x00<br>Binding 
to PKCS#15, rc=0<br>0: Detected framework 0. Creating tokens.<br>Found 1 
authentication objects<br>Found 1 private key<br>Found 0 public keys<br>Found 2 
certificates<br>pkcs15-cert.c:115:sc_pkcs15_read_certificate: called<br>called, 
path=df01c000, index=2, count=1288<br>card.c:514:sc_lock: called<br>called; 
type=2, path=df01c000<br>card-starcos.c:375:starcos_select_file: 
called<br>current path (path, valid):&nbsp; (len: 
0)<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 bytes (resp. 258 
bytes):<br>00 A4 00 00 02 3F 00 00 .....?..<br>Received 0 bytes (SW1=62 
SW2=84)<br>card.c:250:sc_transmit_apdu: called<br>Sending 7 bytes (resp. 258 
bytes):<br>00 A4 00 0C 02 3F 00 .....?.<br>Received 0 bytes (SW1=90 
SW2=00)<br>card-starcos.c:361:starcos_select_fid: returning with: 
0<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 bytes (resp. 258 
bytes):<br>00 A4 00 00 02 DF 01 00 ........<br>Received 0 bytes (SW1=62 
SW2=84)<br>card.c:250:sc_transmit_apdu: called<br>Sending 7 bytes (resp. 258 
bytes):<br>00 A4 00 0C 02 DF 01 .......<br>Received 0 bytes (SW1=90 
SW2=00)<br>card-starcos.c:361:starcos_select_fid: returning with: 
0<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 bytes (resp. 258 
bytes):<br>00 A4 00 00 02 C0 00 00 ........<br>Received 9 bytes (SW1=90 
SW2=00)<br>6F 07 80 02 0A 00 82 01 01 o........<br>card.c:250:sc_transmit_apdu: 
called<br>Sending 5 bytes (resp. 258 bytes):<br>00 B0 00 00 01 .....<br>Received 
1 bytes (SW1=90 SW2=00)<br>08 .<br>processing FCI bytes<br>&nbsp; bytes in file: 
2560<br>&nbsp; type: working EF<br>&nbsp; EF structure: 
transparent<br>card-starcos.c:361:starcos_select_fid: returning with: 
0<br>card.c:759:sc_select_file: returning with: 0<br>called; 1288 bytes at index 
2<br>called; 128 bytes at index 2<br>card.c:250:sc_transmit_apdu: 
called<br>Sending 5 bytes (resp. 258 bytes):<br>00 B0 00 02 80 .....<br>Received 
128 bytes (SW1=90 SW2=00)<br>30 82 05 04 30 82 03 EC A0 03 02 01 02 02 03 02 
0...0...........<br>E4 70 30 0D 06 09 2A 86 48 86 F7 0D 01 01 05 05 
.p0...*.H.......<br>00 30 81 9D 31 0B 30 09 06 03 55 04 06 13 02 49 
.0..1.0...U....I<br>54 31 18 30 16 06 03 55 04 0A 13 0F 49 6E 66 6F 
T1.0...U....Info<br>43 61 6D 65 72 65 20 53 43 70 41 31 14 30 12 06 Camere 
SCpA1.0..<br>03 55 04 05 13 0B 30 32 33 31 33 38 32 31 30 30 
.U....0231382100<br>37 31 37 30 35 06 03 55 04 0B 13 2E 43 65 72 74 
71705..U....Cert<br>69 66 69 63 61 74 6F 72 65 20 41 63 63 72 65 64 ificatore 
Accred<br>iso7816.c:126:iso7816_read_binary: returning with: 
128<br>card.c:640:sc_read_binary: returning with: 128<br>called; 128 bytes at 
index 130<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 00 82 80 .....<br>Received 128 bytes (SW1=90 SW2=00)<br>69 74 
61 74 6F 20 64 65 6C 20 53 69 73 74 65 6D itato del Sistem<br>61 20 43 61 6D 65 
72 61 6C 65 31 25 30 23 06 03 a Camerale1%0#..<br>55 04 03 13 1C 49 6E 66 6F 43 
61 6D 65 72 65 20 U....InfoCamere <br>46 69 72 6D 61 20 51 75 61 6C 69 66 69 63 
61 74 Firma Qualificat<br>61 30 1E 17 0D 30 35 30 33 32 33 30 39 35 32 35 
a0...05032309525<br>37 5A 17 0D 30 38 30 33 32 33 30 30 30 30 30 30 
7Z..080323000000<br>5A 30 81 A8 31 0B 30 09 06 03 55 04 06 13 02 49 
Z0..1.0...U....I<br>54 31 17 30 15 06 03 55 04 0A 13 0E 4E 6F 6E 20 
T1.0...U....Non <br>iso7816.c:126:iso7816_read_binary: returning with: 
128<br>card.c:640:sc_read_binary: returning with: 128<br>called; 128 bytes at 
index 258<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 01 02 80 .....<br>Received 128 bytes (SW1=90 SW2=00)<br>44 69 
63 68 69 61 72 61 74 6F 31 1F 30 1D 06 03 Dichiarato1.0...<br>55 04 0B 13 16 52 
41 3D 43 2E 43 2E 49 2E 41 2E U....RA=C.C.I.A.<br>41 2E 20 44 49 20 50 41 56 49 
41 31 36 30 34 06 A. DI PAVIA1604.<br>03 55 04 03 13 2D 43 41 46 4F 52 49 4F 2F 
4C 55 .U...-CAFORIO/LU<br>49 47 49 2F 43 46 52 4C 47 55 35 38 4C 31 36 42 
IGI/CFRLGU58L16B<br>31 38 30 4C 2F 32 30 30 33 31 31 31 34 38 30 31 
180L/20031114801<br>31 33 31 31 27 30 25 06 03 55 04 0D 13 1E 43 3D 
1311'0%..U....C=<br>43 61 66 6F 72 69 6F 2F 4E 3D 4C 75 69 67 69 2F 
Caforio/N=Luigi/<br>iso7816.c:126:iso7816_read_binary: returning with: 
128<br>card.c:640:sc_read_binary: returning with: 128<br>called; 128 bytes at 
index 386<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 01 82 80 .....<br>Received 128 bytes (SW1=90 SW2=00)<br>44 3D 
31 36 2D 30 37 2D 31 39 35 38 30 81 9F 30 D=16-07-19580..0<br>0D 06 09 2A 86 48 
86 F7 0D 01 01 01 05 00 03 81 ...*.H..........<br>8D 00 30 81 89 02 81 81 00 B5 
72 9D D3 2E A8 C2 ..0.......r.....<br>03 05 C0 E3 8F F6 9C 69 C8 E4 F9 7C 71 B3 
5F 59 .......i...|q._Y<br>C6 60 E6 AF 18 66 AC EC 40 91 59 25 2C DE B8 5A <a href="mailto:.%60...f.. <at> .Y%,..Z">.`...f.. <at> .Y%,..Z</a><br>E3 0F 7F 31 5C 00 41 25 
67 62 41 F6 EC 31 46 34 ...1\.A%gbA..1F4<br>9F C0 F3 4A D3 AC 66 64 74 09 DD E8 
1B 65 7D A1 ...J..fdt....e}.<br>65 B3 FD 47 A9 54 1F 5A 79 20 98 F4 F5 EF 7D 6D 
e..G.T.Zy ....}m<br>iso7816.c:126:iso7816_read_binary: returning with: 
128<br>card.c:640:sc_read_binary: returning with: 128<br>called; 128 bytes at 
index 514<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 02 02 80 .....<br>Received 128 bytes (SW1=90 SW2=00)<br>D8 F4 
0E A2 37 12 D2 C5 E3 B6 8C 15 74 B4 F9 D0 ....7.......t...<br>A4 4E 91 B6 C0 95 
A2 59 9D B2 2A 41 07 9E 09 70 .N.....Y..*A...p<br>DE 06 18 6A A9 0B 3C CB 23 02 
03 01 00 01 A3 82 ...j..&lt;.#.......<br>01 C2 30 82 01 BE 30 50 06 03 55 1D 20 
04 49 30 ..0...0P..U. .I0<br>47 30 45 06 06 2B 4C 0E 01 01 01 30 3B 30 39 06 
G0E..+L....0;09.<br>08 2B 06 01 05 05 07 02 01 16 2D 68 74 74 70 3A 
.+........-http:<br>2F 2F 77 77 77 2E 63 61 72 64 2E 69 6E 66 6F 63 
//www.card.infoc<br>61 6D 65 72 65 2E 69 74 2F 64 6F 63 2F 6D 61 6E 
amere.it/doc/man<br>iso7816.c:126:iso7816_read_binary: returning with: 
128<br>card.c:640:sc_read_binary: returning with: 128<br>called; 128 bytes at 
index 642<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 02 82 80 .....<br>Received 128 bytes (SW1=90 SW2=00)<br>75 61 
6C 69 2E 68 74 6D 30 18 06 08 2B 06 01 05 uali.htm0...+...<br>05 07 01 03 04 0C 
30 0A 30 08 06 06 04 00 8E 46 ......0.0......F<br>01 01 30 0E 06 03 55 1D 0F 01 
01 FF 04 04 03 02 ..0...U.........<br>06 40 30 27 06 03 55 1D 12 04 20 30 1E 81 
1C 66 <a href="mailto:. <at> 0'..U">. <at> 0'..U</a>... 0...f<br>69 72 6D 61 2E 64 69 67 
69 74 61 6C 65 40 69 6E <a href="mailto:irma.digitale <at> in">irma.digitale <at> in</a><br>66 6F 63 61 6D 65 72 65 
2E 69 74 30 1F 06 03 55 focamere.it0...U<br>1D 23 04 18 30 16 80 14 66 5D 69 C7 
E5 E2 50 DC .#..0...f]i...P.<br>5E 69 E4 4E 4E 6E 44 59 96 91 DB 6B 30 81 D6 06 
^i.NNnDY...k0...<br>iso7816.c:126:iso7816_read_binary: returning with: 
128<br>card.c:640:sc_read_binary: returning with: 128<br>called; 128 bytes at 
index 770<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 03 02 80 .....<br>Received 128 bytes (SW1=90 SW2=00)<br>03 55 
1D 1F 04 81 CE 30 81 CB 30 81 C8 A0 81 C5 .U.....0..0.....<br>A0 81 C2 86 81 BF 
6C 64 61 70 3A 2F 2F 6C 64 61 ......ldap://lda<br>70 32 2E 69 6E 66 6F 63 61 6D 
65 72 65 2E 69 74 p2.infocamere.it<br>3A 33 38 39 2F 63 6E 25 33 64 49 6E 66 6F 
43 61 :389/cn%3dInfoCa<br>6D 65 72 65 25 32 30 46 69 72 6D 61 25 32 30 51 
mere%20Firma%20Q<br>75 61 6C 69 66 69 63 61 74 61 25 32 30 43 52 4C 
ualificata%20CRL<br>30 31 2C 6F 75 25 33 64 43 65 72 74 69 66 69 63 
01,ou%3dCertific<br>61 74 6F 72 65 25 32 30 41 63 63 72 65 64 69 74 
atore%20Accredit<br>iso7816.c:126:iso7816_read_binary: returning with: 
128<br>card.c:640:sc_read_binary: returning with: 128<br>called; 128 bytes at 
index 898<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 03 82 80 .....<br>Received 128 bytes (SW1=90 SW2=00)<br>61 74 
6F 25 32 30 64 65 6C 25 32 30 53 69 73 74 ato%20del%20Sist<br>65 6D 61 25 32 30 
43 61 6D 65 72 61 6C 65 2C 6F ema%20Camerale,o<br>25 33 64 49 6E 66 6F 43 61 6D 
65 72 65 25 32 30 %3dInfoCamere%20<br>53 43 70 41 2C 63 25 33 64 49 54 3F 63 65 
72 74 SCpA,c%3dIT?cert<br>69 66 69 63 61 74 65 52 65 76 6F 63 61 74 69 6F 
ificateRevocatio<br>6E 4C 69 73 74 30 1D 06 03 55 1D 0E 04 16 04 14 
nList0...U......<br>99 7A 2C 35 B7 38 36 AC 71 5E A9 FE 43 8D 8E D6 
.z,5.86.q^..C...<br>BB 24 CD A3 30 0D 06 09 2A 86 48 86 F7 0D 01 01 
.$..0...*.H.....<br>iso7816.c:126:iso7816_read_binary: returning with: 
128<br>card.c:640:sc_read_binary: returning with: 128<br>called; 128 bytes at 
index 1026<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 04 02 80 .....<br>Received 128 bytes (SW1=90 SW2=00)<br>05 05 
00 03 82 01 01 00 4B 2F 12 58 9B 72 EF 83 ........K/.X.r..<br>D5 A7 18 CF B2 B8 
37 C1 EA 2D 29 09 22 95 00 2F ......7..-)."../<br>18 6C 39 33 FC 9F 4A DE 4E B7 
A5 2D 41 89 1B F0 .l93..J.N..-A...<br>68 57 2A 51 E0 D3 FE B8 88 6B 38 0B E1 DD 
A6 76 hW*Q.....k8....v<br>E9 AE 7E 3C 0B F6 57 35 E3 E3 C7 02 A7 2F 79 69 
..~&lt;..W5...../yi<br>BC 8C 7F 0B DA FB 03 5A 6B D9 6B AD F8 DD 66 08 
.......Zk.k...f.<br>02 9B 83 DD 48 F8 6A 9A FC 7B 83 E1 BB 91 D0 66 
....H.j..{.....f<br>AD 30 28 CB A5 53 E3 92 95 82 30 B7 D0 83 36 BA 
.0(..S....0...6.<br>iso7816.c:126:iso7816_read_binary: returning with: 
128<br>card.c:640:sc_read_binary: returning with: 128<br>called; 128 bytes at 
index 1154<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 04 82 80 .....<br>Received 128 bytes (SW1=90 SW2=00)<br>A0 4D 
AA E7 10 AF 62 33 07 D0 5A 83 29 07 7F 97 .M....b3..Z.)...<br>A2 B4 80 D7 3E 3C 
02 29 6B E3 99 3D F3 59 E6 B4 ....&gt;&lt;.)k..=.Y..<br>25 88 4A 03 B9 AE 61 FE 
5B 72 43 ED 92 43 C0 71 %.J...a.[rC..C.q<br>41 73 F2 99 88 E8 9B 64 2D DF 3F 72 
C5 94 29 DE As.....d-.?r..).<br>1C C0 06 37 B9 44 FE 92 82 D1 A5 7D 25 84 91 A7 
...7.D.....}%...<br>A8 E3 A9 7E 9B DC A7 F8 5A 20 72 46 33 0A 2C F1 ...~....Z 
rF3.,.<br>B1 5E 29 AB 4C 34 81 BF EB A8 43 54 47 46 33 E9 .^).L4....CTGF3.<br>71 
86 EA AA AB 9B 3F 32 2C 7D C0 58 CD 63 AA 94 
q.....?2,}.X.c..<br>iso7816.c:126:iso7816_read_binary: returning with: 
128<br>card.c:640:sc_read_binary: returning with: 128<br>called; 8 bytes at 
index 1282<br>card.c:250:sc_transmit_apdu: called<br>Sending 5 bytes (resp. 258 
bytes):<br>00 B0 05 02 08 .....<br>Received 8 bytes (SW1=90 SW2=00)<br>E3 3A 1C 
53 FE E3 0E 27 .:.S...'<br>iso7816.c:126:iso7816_read_binary: returning with: 
8<br>card.c:640:sc_read_binary: returning with: 8<br>card.c:637:sc_read_binary: 
returning with: 1288<br>card.c:534:sc_unlock: called<br>Calling card logout 
function<br>card.c:250:sc_transmit_apdu: called<br>Sending 7 bytes (resp. 258 
bytes):<br>00 A4 00 0C 02 3F 00 .....?.<br>Received 0 bytes (SW1=90 
SW2=00)<br>sw1 = 0x90, sw2 = 0x00<br>called, left=1284, depth 0<br>Looking for 
'tbsCertificate', tag 0x1000010<br>decoding 'tbsCertificate'<br>&nbsp;called, 
left=1004, depth 1<br>Looking for 'version', tag 0x21000000, 
OPTIONAL<br>&nbsp;decoding 'version'<br>&nbsp; called, left=3, depth 
2<br>Looking for 'version', tag 0x2<br>&nbsp; decoding 
'version'<br>asn1.c:1102:asn1_decode: returning with: 0<br>Looking for 
'serialNumber', tag 0x2<br>&nbsp;decoding 'serialNumber'<br>Looking for 
'signature', tag 0x1000010<br>&nbsp;decoding 'signature'<br>Looking for 
'issuer', tag 0x1000010<br>&nbsp;decoding 'issuer'<br>Looking for 'validity', 
tag 0x1000010<br>&nbsp;decoding 'validity'<br>Looking for 'subject', tag 
0x1000010<br>&nbsp;decoding 'subject'<br>Looking for 'subjectPublicKeyInfo', tag 
0x1000010<br>&nbsp;decoding 'subjectPublicKeyInfo'<br>&nbsp; called, left=159, 
depth 2<br>Looking for 'algorithm', tag 0x1000010<br>&nbsp; decoding 
'algorithm'<br>&nbsp;&nbsp; called, left=13, depth 3<br>Looking for 'algorithm', 
tag 0x6<br>&nbsp;&nbsp; decoding 'algorithm'<br>Looking for 'nullParam', tag 
0x5, OPTIONAL<br>&nbsp;&nbsp; decoding 'nullParam'<br>asn1.c:1102:asn1_decode: 
returning with: 0<br>Looking for 'subjectPublicKey', tag 0x3<br>&nbsp; decoding 
'subjectPublicKey'<br>asn1.c:1102:asn1_decode: returning with: 0<br>Looking for 
'extensions', tag 0x21000003, OPTIONAL<br>&nbsp;decoding 'extensions'<br>&nbsp; 
called, left=450, depth 2<br>Looking for 'x509v3', tag 0x1000010, 
OPTIONAL<br>&nbsp; decoding 'x509v3'<br>&nbsp;&nbsp; called, left=446, depth 
3<br>Looking for 'certificatePolicies', tag 0x1000010, OPTIONAL<br>&nbsp;&nbsp; 
decoding 'certificatePolicies'<br>Looking for 'subjectKeyIdentifier', tag 
0x1000010, OPTIONAL<br>&nbsp;&nbsp; decoding 'subjectKeyIdentifier'<br>Looking 
for 'crlDistributionPoints', tag 0x1000010, OPTIONAL<br>&nbsp;&nbsp; decoding 
'crlDistributionPoints'<br>Looking for 'authorityKeyIdentifier', tag 0x1000010, 
OPTIONAL<br>&nbsp;&nbsp; decoding 'authorityKeyIdentifier'<br>Looking for 
'keyUsage', tag 0x1000010, OPTIONAL<br>&nbsp;&nbsp; decoding 
'keyUsage'<br>asn1.c:1102:asn1_decode: returning with: 
0<br>asn1.c:1102:asn1_decode: returning with: 0<br>asn1.c:1102:asn1_decode: 
returning with: 0<br>Looking for 'signatureAlgorithm', tag 0x1000010<br>decoding 
'signatureAlgorithm'<br>&nbsp;called, left=13, depth 1<br>Looking for 
'algorithm', tag 0x6<br>&nbsp;decoding 'algorithm'<br>Looking for 'nullParam', 
tag 0x5, OPTIONAL<br>&nbsp;decoding 'nullParam'<br>asn1.c:1102:asn1_decode: 
returning with: 0<br>Looking for 'signatureValue', tag 0x3<br>decoding 
'signatureValue'<br>asn1.c:1102:asn1_decode: returning with: 0<br>called, 
left=140, depth 0<br>Looking for 'publicKeyCoefficients', tag 
0x1000010<br>decoding 'publicKeyCoefficients'<br>&nbsp;called, left=137, depth 
1<br>Looking for 'modulus', tag 0x2<br>&nbsp;decoding 'modulus'<br>Looking for 
'exponent', tag 0x2<br>&nbsp;decoding 'exponent'<br>asn1.c:1102:asn1_decode: 
returning with: 0<br>asn1.c:1102:asn1_decode: returning with: 
0<br>pkcs15-cert.c:115:sc_pkcs15_read_certificate: called<br>called, 
path=df01c008, index=2, count=0<br>card.c:514:sc_lock: called<br>called; type=2, 
path=df01c008<br>card-starcos.c:375:starcos_select_file: called<br>current path 
(path, valid):&nbsp; (len: 0)<br>card.c:250:sc_transmit_apdu: called<br>Sending 
8 bytes (resp. 258 bytes):<br>00 A4 00 00 02 3F 00 00 .....?..<br>Received 0 
bytes (SW1=62 SW2=84)<br>card.c:250:sc_transmit_apdu: called<br>Sending 7 bytes 
(resp. 258 bytes):<br>00 A4 00 0C 02 3F 00 .....?.<br>Received 0 bytes (SW1=90 
SW2=00)<br>card-starcos.c:361:starcos_select_fid: returning with: 
0<br>card.c:250:sc_transmit_apdu: called<br>Sending 8 bytes (resp. 258 
bytes):<br>00 A4 00 00 02 DF 01 00 ........<br>Received 0 bytes (SW1=62 
SW2=84)<br>card.c:250:sc_transmit_apdu: 
called<br>**************************************************************≤/div>
<div>&nbsp;</div>
<div>&nbsp;</div>
</div>
Nils Larsch | 4 Oct 20:42 2005
Picon
Picon

Re: [INFOCAMERE STARCOS 2.3 CARD] Invalid ASN.1 object

Pier Paolo Bortone wrote:
...
> First element *********************************************************
> DUMP COMMAND RESULT + RELATIVE ERRORS LOG
> C:\Programmi\Smart card bundle>p15dump.exe
> Using libopensc version 0.9.4.
> Card detected in reader 'CASTLES EZ100PU 0'
> Connecting... connected.
> ATR = 3b:b7:94:00:81:31:fe:65:53:50:4b:32:33:90:00:d1
> Looking for a PKCS#15 compatible Smart Card... found.
> PKCS#15 Card [Infocamere 1202 Card]:
>         Version        : 0
>         Serial number  : d2760000012590154800131c13
>         Manufacturer ID: Infocamere
>         Flags          :
> Enumerating PIN codes... 1 found.
> PIN [Non-repudiation PIN]
>         Com. Flags  : private, modifiable
>         Auth ID     : 02
>         Flags       : [0x31], case-sensitive, initialized, needs-padding
>         Length      : min_len:5, max_len:8, stored_len:8
>         Pad char    : 0x00
>         Reference   : 153
>         Encoding    : ASCII-numeric
>         Path        : 3F00DF01
>         Tries left  : 3
> Enumerating Private keys... 1 found.
> Private RSA key [Non repudiation Key]
>         Com. Flags  : private
>         Com. Auth ID: 02
>         Usage       : [0x200], nonRepudiation
>         Access Flags: [0x1D], sensitive, alwaysSensitive, neverExtract, 
> local
>         ModLength   : 1024
>         Key ref     : 132
>         Native      : yes
>         Path        : 3F00DF01
>         ID          : 02
> Enumerating Public keys... none found.
> Enumerating X.509 certificates... 2 found.
> X.509 Certificate [User Non-repudiation Certificate]
>         Com. Flags  : modifiable
>         Authority   : no
>         Path        : df01c000
>         ID          : 02
> X.509 Certificate [CA Certificate]
>         Com. Flags  : modifiable
>         Authority   : yes
>         Path        : df01c008
>         ID          : 03
> Enumerating data objects... none found.
>  
> opensc-errors.log:
>  
> File not found
> card-starcos.c:317:starcos_select_fid: returning with: File not found
> card.c:759:sc_select_file: returning with: File not found

is the above dump correct or is there something missing/wrong ?

> ***********************************************************************
>  
> Second element ********************************************************
> TRY TO READ CERTIFICATE WITH ID 03 + RELATIVE DEBUG & ERRORS LOG
> C:\Programmi\Smart card bundle>pkcs15-tool.exe --read-certificate 03
> Certificate read failed: Invalid ASN.1 object

could you verify the there's a certificate in 3F00/DF01/C008
(using opensc-explorer with the get command, and could you send
me the file dump).

...
> trying infocamere
> called; type=2, path=3f002f02
> card-starcos.c:375:starcos_select_file: called
> current path (path, valid): 3F00 (len: 2)
> card.c:250:sc_transmit_apdu: called
> Sending 8 bytes (resp. 258 bytes):
> 00 A4 00 00 02 2F 02 00 ...../..
> Received 9 bytes (SW1=90 SW2=00)
> 6F 07 80 02 00 1A 82 01 01 o........
> card.c:250:sc_transmit_apdu: called
> Sending 5 bytes (resp. 258 bytes):
> 00 B0 00 00 01 .....
> Received 1 bytes (SW1=90 SW2=00)
> 5A Z
> processing FCI bytes
>   bytes in file: 26
>   type: working EF
>   EF structure: transparent
> card-starcos.c:361:starcos_select_fid: returning with: 0
> card.c:759:sc_select_file: returning with: 0
> called; 26 bytes at index 0
> card.c:250:sc_transmit_apdu: called
> Sending 5 bytes (resp. 258 bytes):
> 00 B0 00 00 1A .....
> Received 26 bytes (SW1=90 SW2=00)
> 5A 0D D2 76 00 00 01 25 90 15 48 00 13 1C 13 5F Z..v...%..H...._
> 20 08 12 02 05 00 00 77 78 25                    ......wx%
> iso7816.c:126:iso7816_read_binary: returning with: 26
> card.c:640:sc_read_binary: returning with: 26
> called; type=2, path=11111a02
> card-starcos.c:375:starcos_select_file: called
> current path (path, valid): 3F00 (len: 2)
> card.c:250:sc_transmit_apdu: called
> Sending 8 bytes (resp. 258 bytes):
> 00 A4 00 00 02 11 11 00 ........
> Received 0 bytes (SW1=62 SW2=84)
> card.c:250:sc_transmit_apdu: called
> Sending 7 bytes (resp. 258 bytes):
> 00 A4 00 0C 02 11 11 .......
> Received 0 bytes (SW1=90 SW2=00)
> card-starcos.c:361:starcos_select_fid: returning with: 0
> card-starcos.c:375:starcos_select_file: called
> current path (path, valid): 3F001111 (len: 4)
> card.c:250:sc_transmit_apdu: called
> Sending 8 bytes (resp. 258 bytes):
> 00 A4 00 00 02 1A 02 00 ........
> Received 0 bytes (SW1=6A SW2=82)
> sw1 = 0x6a, sw2 = 0x82
> File not found
> card-starcos.c:317:starcos_select_fid: returning with: -1201
> card.c:759:sc_select_file: returning with: -1201
> called; type=2, path=df01c000
> card-starcos.c:375:starcos_select_file: called

according to the infocamere driver there should be 1A02
DF on your token ...

Cheers,
Nils
Andreas Jellinghaus | 4 Oct 21:37 2005
Picon

Re: R: R: [Snapshot] - Help - Win32 0.9.6 Snapshot

On Tuesday 04 October 2005 19:20, Pier Paolo Bortone wrote:
> I want to tell you I succesfully installed SCB modifying somethings:
> in file opensc.conf I changed
> 	profile_dir = PKGDATADIR; 
> to
> 	profile_dir = "C:\Programmi\Smart Card Bundle";

scb 0.5-pre1e should do that itself, the last step is
"view editconf.exe" (need to fix that description)
which runs a program to edit the opensc.conf file
and change the profile_dir entry. 

maybe you unchecked that box?
(guess I should reconfigure the installer,
so it is alway run without even asking?)

Andreas
ant_iacono | 4 Oct 21:58 2005
Picon

Re: [INFOCAMERE STARCOS 2.3 CARD] Invalid ASN.1 object

On Tuesday 04 October 2005 20:42, Nils Larsch wrote:
> Pier Paolo Bortone wrote:
[...]
> > card-starcos.c:317:starcos_select_fid: returning with: -1201
> > card.c:759:sc_select_file: returning with: -1201
> > called; type=2, path=df01c000
> > card-starcos.c:375:starcos_select_file: called
>
> according to the infocamere driver there should be 1A02
> DF on your token ...
>

Hi Pier, Nils and all

this certificate (1A02) is optional [1]. This and other bug have been 
corrected in the trunk version of pkcs15-infocamere.c
Please, considers the idea to insert it in the stable version
Thanks,

Antonio

[1] ...
/* Get the authentication certificate length */

        sc_format_path(infocamere_auth_certpath[ef_gdo[len_iccsn+6]-2], 
&path);

        card->ctx->suppress_errors++;
        r = sc_select_file(card, &path, NULL);
        card->ctx->suppress_errors--;

        if (r >= 0) {
...

--

-- 
http://opensignature.sourceforge.net
Nils Larsch | 4 Oct 22:25 2005
Picon
Picon

Re: [INFOCAMERE STARCOS 2.3 CARD] Invalid ASN.1 object

ant_iacono <at> tin.it wrote:
> On Tuesday 04 October 2005 20:42, Nils Larsch wrote:
> 
>>Pier Paolo Bortone wrote:
> 
> [...]
> 
>>>card-starcos.c:317:starcos_select_fid: returning with: -1201
>>>card.c:759:sc_select_file: returning with: -1201
>>>called; type=2, path=df01c000
>>>card-starcos.c:375:starcos_select_file: called
>>
>>according to the infocamere driver there should be 1A02
>>DF on your token ...
>>
> 
> 
> Hi Pier, Nils and all
> 
> this certificate (1A02) is optional [1]. This and other bug have been 
> corrected in the trunk version of pkcs15-infocamere.c
> Please, considers the idea to insert it in the stable version

quite soon the trunk version will be the stable version (0.10
is approaching) and afaik the scb version Pier tested should
already use a recent snapshot from the trunk.

Cheers,
Nils
Nils Larsch | 4 Oct 23:24 2005
Picon
Picon

Re: [INFOCAMERE STARCOS 2.3 CARD] Invalid ASN.1 object

Pier Paolo Bortone wrote:
...
> First element *********************************************************
> DUMP COMMAND RESULT + RELATIVE ERRORS LOG
> C:\Programmi\Smart card bundle>p15dump.exe
...
> X.509 Certificate [CA Certificate]
>         Com. Flags  : modifiable
>         Authority   : yes
>         Path        : df01c008
>         ID          : 03
> Enumerating data objects... none found.
>  
> opensc-errors.log:
>  
> File not found
> card-starcos.c:317:starcos_select_fid: returning with: File not found
> card.c:759:sc_select_file: returning with: File not found

I think this one is caused by the opensc pkcs15 routines trying to
check whether the card has a pkcs15 compliant layout. It might be a
good idea to suppress errors there as well ... Setting
"try_emulation_first = yes;" in your opensc.conf file might 'fix'
this 'error' message.

Cheers,
Nils

Gmane