Index: build/certs/commercial/kps-ca-1.crt ================================================================== --- build/certs/commercial/kps-ca-1.crt +++ build/certs/commercial/kps-ca-1.crt @@ -1,7 +1,7 @@ -----BEGIN CERTIFICATE----- -MIIEfTCCA2WgAwIBAgICJxAwDQYJKoZIhvcNAQELBQAwgawxCzAJBgNVBAYTAlVT +MIIEezCCA2OgAwIBAgICJxEwDQYJKoZIhvcNAQELBQAwgawxCzAJBgNVBAYTAlVT MREwDwYDVQQIEwhWaXJnaW5pYTEPMA0GA1UEBxMGUmVzdG9uMSAwHgYDVQQKExdL bmlnaHRQb2ludCBTeXN0ZW1zIExMQzEXMBUGA1UECxMOS25pZ2h0UG9pbnQgSVQx GDAWBgNVBAsTD0tuaWdodFBvaW50IFBLSTEkMCIGA1UEAxMbS25pZ2h0UG9pbnQg U3lzdGVtcyBSb290IENBMB4XDTE1MDEwMTAwMDAwMFoXDTIwMDEwMTAwMDAwMFow gakxCzAJBgNVBAYTAlVTMREwDwYDVQQIEwhWaXJnaW5pYTEPMA0GA1UEBxMGUmVz @@ -11,18 +11,17 @@ AQ8AMIIBCgKCAQEAxQdIWZQsGRSFJ/3x5P1G3omvP6Z6Qv8rlrPqInAbPUr4a2TT CPGmJp1IcmjHxPm8Sa2UgmHRn35vVScVr/7Lifgq/vYHcVgVqap3MO/GoAjWuTqN pbaoxSBOpkwnfUBOgpzSSVHNcrGWs/VplrgNYvREOMm1fpe22jprxOzDVH+rD3sP luNkI4lo64vcc6V05d34XGMTafw8eRl8ySKVfhIORZcSp/j++R1CaVdqqR8wM0eY DF4nntTtT6IKktcpVkLGOtH0vXiImMdPEeiXjekiEq/DDrGrVrHqR2vJXIfjUiFX -luEIQ/TTh9yVA4ExkfGgdkrZrkBRDvvXWjFjHwIDAQABo4GpMIGmMCAGA1UdDgEB +luEIQ/TTh9yVA4ExkfGgdkrZrkBRDvvXWjFjHwIDAQABo4GnMIGkMCAGA1UdDgEB AAQWBBQ4LgWOLupZrGEOIQCvWkCBLwOTcDASBgNVHRMBAf8ECDAGAQH/AgEBMDcG A1UdHwEBAAQtMCswKaAnoCWGI2h0dHA6Ly9wa2kua25pZ2h0cG9pbnQuY29tL2Ny -bC9yb290MA8GA1UdDwEB/wQFAwMHhgAwJAYDVR0jAQEABBowGKAWBBQ5k0zyzDhs -X4G3Lr8tKuBZMyEqnjANBgkqhkiG9w0BAQsFAAOCAQEAT6vuDz9WLADBLII9CJYc -9N69OOELuDb9E4bAj/93E9S5WpZsa/nMud5kgdLiLSlsD71Pu3lUaDxPi0lOnbI0 -7g3JXNEpOvNSDBnVVD0jPC4nj2XpNFSVue1mpP5bWYHyzbruEjJtoTPzvE0an6Bp -Cl96uA5MFWyKsgWtwZSnX+Ru05vSLWI7jjcAkGW+atV/iPe0vwtFJR/RiQUKyqsa -We3Xyw+T0x0UwlpKMhS7d3A+f/4pVtaLtCvLZKYyLAaji+DxlIM4WIPZ0IOD/Xbb -YagEem5bnPlmugrnGCxovJW2mBKm3iSSvZi0nW2TEVigHaBULItFRrF9J+d+8aG+ -TQ== +bC9yb290MA8GA1UdDwEB/wQFAwMHhgAwIgYDVR0jAQEABBgwFoAUOZNM8sw4bF+B +ty6/LSrgWTMhKp4wDQYJKoZIhvcNAQELBQADggEBAHx0X9PkIWLPUlYWOyY1eJZs +7yPiqNFcnFM4CFCCP+Iirv6SND13DCCUD/XajQR0O9HkeGd2VgezEa7jmSTegWjK +mv1xMqMxlT9BgrOBweMFl0q1eeYRCO/JKKilNab6x1GS84e81McrCKx0SFVBnYjD +U9SPBRdNUYCgoQhrXL2uQ5R8Cid4dwdOptkM7XmRyKUM0LZvbCqR2VOzbtztL/UM +bY8fD/KnPdQe29BtymDU3X6zrGjNyj1Gq/3zKA03RhrPGxZJkvHrf8DkYkhtD5/l +q7aLkdtHICtte7BS/IaQl7bhCcOlar6Kt8dTPDhZueNy18rZqFJyq65ZW6ktxgw= -----END CERTIFICATE----- ADDED build/certs/commercial/kps-root-ca-crl.crt Index: build/certs/commercial/kps-root-ca-crl.crt ================================================================== --- /dev/null +++ build/certs/commercial/kps-root-ca-crl.crt @@ -0,0 +1,26 @@ +-----BEGIN CERTIFICATE----- +MIIEbjCCA1agAwIBAgICB9AwDQYJKoZIhvcNAQELBQAwgawxCzAJBgNVBAYTAlVT +MREwDwYDVQQIEwhWaXJnaW5pYTEPMA0GA1UEBxMGUmVzdG9uMSAwHgYDVQQKExdL +bmlnaHRQb2ludCBTeXN0ZW1zIExMQzEXMBUGA1UECxMOS25pZ2h0UG9pbnQgSVQx +GDAWBgNVBAsTD0tuaWdodFBvaW50IFBLSTEkMCIGA1UEAxMbS25pZ2h0UG9pbnQg +U3lzdGVtcyBSb290IENBMB4XDTE1MDEwMTAwMDAwMFoXDTM1MDEwMTAwMDAwMFow +gawxCzAJBgNVBAYTAlVTMREwDwYDVQQIEwhWaXJnaW5pYTEPMA0GA1UEBxMGUmVz +dG9uMSAwHgYDVQQKExdLbmlnaHRQb2ludCBTeXN0ZW1zIExMQzEXMBUGA1UECxMO +S25pZ2h0UG9pbnQgSVQxGDAWBgNVBAsTD0tuaWdodFBvaW50IFBLSTEkMCIGA1UE +AxMbS25pZ2h0UG9pbnQgU3lzdGVtcyBSb290IENBMIIBIjANBgkqhkiG9w0BAQEF +AAOCAQ8AMIIBCgKCAQEAxCweWY/eRfRiWGzB5zPiuZg5X3r+WmkQZllRVQ2N/gxP +S2TRLvuJGpvy3T/NdhT/Kkd0DZXz4C4fBd2w26d2bEhl+cVWNJo+fQSZgowbt9gA +Yh1pf21Hkq2Qux/yOXFghNXykETcrRigcJVXIuSaNMCNpnVLb+nkOkh9xBaZXqCG +KinKhgeUE9kq06hBPz36l2ds3x5ymjYxipffeIjIeam8P/BaVtFFsxD9wPov4G8N +z88lcJb7znWfgYlC/t4lJGaWvMg7OCSOwe2kCWQkPjG0avIH3HACGapEm4m/7n9q +jSqR0sJMw/it14t6Z2XUPdPjJ+ptf5xOEoW9d5TBvwIDAQABo4GXMIGUMBIGCSsG +AQUFBzABBQEBAAQCBQAwIAYDVR0OAQEABBYEFKPVbX6Njigl8loa5aYmAHMmjoWG +MA8GA1UdDwEB/wQFAwMHAgAwDwYDVR0TAQEABAUwAwEB/zAWBgNVHSUBAQAEDDAK +BggrBgEFBQcDCTAiBgNVHSMBAQAEGDAWgBQ5k0zyzDhsX4G3Lr8tKuBZMyEqnjAN +BgkqhkiG9w0BAQsFAAOCAQEAA492XT48XfUtOgsvHrHNJ1gpanjsheziskuOyhpP +bIzmwXYlaiYNiYm0NjZ3Y+rLW26gYUTCmFUPNkVibxC9RsqxBUMlyg33XL+2Qd1p +CUvhS9uRcwUJnn5ujNKpWZnUWE1/b3iVlGqeUaO4hhPtbA+i0PJ1Eocd1SLR7L6k +ZH4aOB/lgAR8vLHvgViiA9FzxprAJKG1nRl3VEosjkLY4z4ukDGP/lw/VypoxNkT +4ftWay1IuGUeG5bBoANd/9Xdcs1dxVGmUi95r4PU7RS39DsG8A09Fi2QZCu/JpbM +pFR+x1zxLo31oth4bxE0C4mUSlU6oyV4ULFNoQoFrHN6Dg== +-----END CERTIFICATE----- Index: build/certs/commercial/kps-root-ca.crt ================================================================== --- build/certs/commercial/kps-root-ca.crt +++ build/certs/commercial/kps-root-ca.crt @@ -1,25 +1,25 @@ -----BEGIN CERTIFICATE----- -MIIERjCCAy6gAwIBAgIGAUvsEnbkMA0GCSqGSIb3DQEBCwUAMIGsMQswCQYDVQQG -EwJVUzERMA8GA1UECBMIVmlyZ2luaWExDzANBgNVBAcTBlJlc3RvbjEgMB4GA1UE -ChMXS25pZ2h0UG9pbnQgU3lzdGVtcyBMTEMxFzAVBgNVBAsTDktuaWdodFBvaW50 -IElUMRgwFgYDVQQLEw9LbmlnaHRQb2ludCBQS0kxJDAiBgNVBAMTG0tuaWdodFBv -aW50IFN5c3RlbXMgUm9vdCBDQTAeFw0xNTAxMDEwMDAwMDBaFw0zNTAxMDEwMDAw -MDBaMIGsMQswCQYDVQQGEwJVUzERMA8GA1UECBMIVmlyZ2luaWExDzANBgNVBAc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zAPBgNV +HQ8BAf8EBQMDB4QAMCIGA1UdIwEBAAQYMBaAFDmTTPLMOGxfgbcuvy0q4FkzISqe +MA0GCSqGSIb3DQEBCwUAA4IBAQBKb+Fl5qUlL4sl3ny13dcgulRbkvGkdst6BX6s +yrNFPukE/k6I63WtVDudQHGkeYlWoRp166pITRzReYql1RN1vpJmycUXXZAYs6rY +PPz2XywuUfRbxlw7WJDgAsvr6uz8ecxdXrfg+yUI5Ugj1cQmQbJwh1yAUH0puLjA +10MRL+ZnPmz70wfm9fYMKH0ub3Na/+fL1uM9iJkk3vlqlp/b6CWrPOAyoDUJO10c +M7DujHmfKGZDYeKOrJF24vbNMRS7pLU1NKgzznvly7yyQIkFpqIQJJEzbbhtVxIF +BRqV+jD10OOvTMg+sIlcjZq8CMKb9MvTNAWb1/mGHn9ultzf -----END CERTIFICATE----- Index: cackey.c ================================================================== --- cackey.c +++ cackey.c @@ -1444,10 +1444,13 @@ * RETURN VALUE * CACKEY_PCSC_S_OK On success * CACKEY_PCSC_E_GENERIC On error * CACKEY_PCSC_E_TOKENABSENT If the sending failed because the token is * absent + * CACKEY_PCSC_E_RETRY If something that looks retry'able went + * wrong -- try the whole transaction over + * again * * NOTES * This function will connect to the PC/SC Connection Manager via * cackey_pcsc_connect() if needed. * @@ -2991,11 +2994,15 @@ cackey_mark_slot_reset(slot); return(CACKEY_PCSC_E_TOKENABSENT); } - return(-1); + CACKEY_DEBUG_PRINTF("Something went wrong during signing, resetting the slot and hoping for the best."); + + cackey_mark_slot_reset(slot); + + return(CACKEY_PCSC_E_GENERIC); } tmpbuf += bytes_to_send; tmpbuflen -= bytes_to_send;