makdimka077 / xades4j

Automatically exported from code.google.com/p/xades4j
GNU Lesser General Public License v3.0
0 stars 0 forks source link

sun.security.pkcs11.wrapper.PKCS11Exception: CKR_TOKEN_NOT_RECOGNIZED #67

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I can't sign.

What is the expected output? What do you see instead?
The expected output is a successful signing.

What version of the product are you using? On what operating system?
The version of product is xades4j-1.3.0 and the O.S is windows 7 32 bit.

Please provide any additional information below.

My card reader is ACS ACR38T and ibrary is akisp11.dll.

Testcase: testSignBES(xades4j.production.SignerBESTest):    Caused an ERROR
Initialization failed
java.security.ProviderException: Initialization failed
    at sun.security.pkcs11.SunPKCS11.<init>(SunPKCS11.java:374)
    at sun.security.pkcs11.SunPKCS11.<init>(SunPKCS11.java:107)
    at xades4j.providers.impl.PKCS11KeyStoreKeyingDataProvider$1.getBuilder(PKCS11KeyStoreKeyingDataProvider.java:115)
    at xades4j.providers.impl.KeyStoreKeyingDataProvider.ensureInitialized(KeyStoreKeyingDataProvider.java:175)
    at xades4j.providers.impl.KeyStoreKeyingDataProvider.getSigningCertificateChain(KeyStoreKeyingDataProvider.java:189)
    at xades4j.production.SignerBES.sign(SignerBES.java:151)
    at xades4j.production.SignerBES.sign(SignerBES.java:122)
    at xades4j.production.SignerBESTest.testSignBES(SignerBESTest.java:67)
Caused by: sun.security.pkcs11.wrapper.PKCS11Exception: CKR_TOKEN_NOT_RECOGNIZED
    at sun.security.pkcs11.wrapper.PKCS11.C_GetTokenInfo(Native Method)
    at sun.security.pkcs11.Token.<init>(Token.java:130)
    at sun.security.pkcs11.SunPKCS11.initToken(SunPKCS11.java:804)
    at sun.security.pkcs11.SunPKCS11.<init>(SunPKCS11.java:365)

Original issue reported on code.google.com by ereny...@gmail.com on 17 May 2013 at 11:16

GoogleCodeExporter commented 9 years ago
Did you overcome this issue?

Original comment by luis.fgoncalv on 4 Sep 2013 at 10:38

GoogleCodeExporter commented 9 years ago

Original comment by luis.fgoncalv on 11 May 2014 at 9:42