JDK-6993711 : Intermitent exception: sun.security.pkcs11.wrapper.PKCS11Exception: CKR_OPERATIO
  • Type: Bug
  • Component: security-libs
  • Sub-Component: java.security
  • Affected Version: 6u20
  • Priority: P4
  • Status: Closed
  • Resolution: Duplicate
  • OS: solaris_9
  • CPU: sparc
  • Submitted: 2010-10-21
  • Updated: 2014-11-17
  • Resolved: 2011-06-23
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 6 JDK 7
6-poolResolved 7-poolResolved
Related Reports
Duplicate :  
Relates :  
Description
Platform:
# uname -a
SunOS zcyds306ha 5.10 Generic_142900-15 sun4u sparc SUNW,Netra-440

JRE version:
# ./java -version
java version "1.6.0_20"
Java(TM) SE Runtime Environment (build 1.6.0_20-b02)
Java HotSpot(TM) Server VM (build 16.3-b01, mixed mode)

Stack Trace:
com.nortel.oam.security.datamanagement.cli.bulkSSData.BulkSSDataImportProcessor.processExceptionHandling(BulkSSDataImportProcessor.java:1144)
        at com.nortel.oam.security.datamanagement.cli.bulkSSData.BulkSSDataImportProcessor.addRoles(BulkSSDataImportProcessor.java:319)
        at com.nortel.oam.security.datamanagement.cli.bulkSSData.BulkSSDataImportProcessor.processSSData(BulkSSDataImportProcessor.java:159)
        at com.nortel.oam.security.datamanagement.cli.bulkSSData.BulkSSDataProcessor.main(BulkSSDataProcessor.java:232)
Caused by: java.security.ProviderException: doFinal() failed
        at sun.security.pkcs11.P11Cipher.implDoFinal(P11Cipher.java:711)
        at sun.security.pkcs11.P11Cipher.engineDoFinal(P11Cipher.java:479)
        at sun.security.pkcs11.P11Cipher.engineDoFinal(P11Cipher.java:462)
        at javax.crypto.Cipher.doFinal(DashoA13*..)
        at com.sun.net.ssl.internal.ssl.CipherBox.dispose(CipherBox.java:482)
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.closeInternal(SSLSocketImpl.java:1423)
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.close(SSLSocketImpl.java:1313)
        at com.sun.jndi.ldap.Connection.cleanup(Connection.java:629)
        at com.sun.jndi.ldap.LdapClient.close(LdapClient.java:415)
        at com.sun.jndi.ldap.LdapCtx.closeConnection(LdapCtx.java:2758)
        at com.sun.jndi.ldap.LdapCtx.close(LdapCtx.java:2545)
        at javax.naming.InitialContext.close(InitialContext.java:531)
        at com.nortel.oam.security.directory.DirectoryCommunicator.shutdown(DirectoryCommunicator.java:2519)
        at com.nortel.oam.security.directory.DirectoryCommunicator.shutdown(DirectoryCommunicator.java:2505)
        at com.nortel.oam.security.datamanagement.client.SecuritySettingsManager.getSecuritySettings(SecuritySettingsManager.java:174)
        at com.nortel.oam.security.datamanagement.client.SSCharacterManager.getChars(SSCharacterManager.java:367)
        at com.nortel.oam.security.datamanagement.client.SSCharacterManager.getRoleNameAllowedChars(SSCharacterManager.java:242)
        at com.nortel.oam.security.datamanagement.client.SSCharacterManager.validateRoleName(SSCharacterManager.java:188)
        at com.nortel.mft.security.iscommunicationmodule.communication.RoleManagerC.checkForSpecialCharacters(RoleManagerC.java:313)
        at com.nortel.mft.security.iscommunicationmodule.communication.RoleManagerC.addSSRole(RoleManagerC.java:1460)
        at com.nortel.oam.security.datamanagement.client.UnixSecurityDataManager.addRole(UnixSecurityDataManager.java:359)
        at com.nortel.oam.security.datamanagement.cli.bulkSSData.BulkSSDataImportProcessor.addRoles(BulkSSDataImportProcessor.java:309)
        ... 2 more
Caused by: sun.security.pkcs11.wrapper.PKCS11Exception: CKR_OPERATION_NOT_INITIALIZED
        at sun.security.pkcs11.wrapper.PKCS11.C_DecryptFinal(Native Method)
        at sun.security.pkcs11.P11Cipher.implDoFinal(P11Cipher.java:704)
        ... 23 more

According to above stack trace, it is very similar to another sun bugs which report on JDK 5:
http://bugs.sun.com/bugdatabase/view_bug.do;jsessionid=2e861771ada9bbffffffffa0a0b90b3a4f887?bug_id=6931964
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6924489

If yes, looks like this bug exists in JDK6 as well

Comments
EVALUATION No updates from Cu. I'm closing this since I believe it's been corrected by CR 7025227 & CR 6932403.
23-06-2011

EVALUATION This is very likely a duplicate of 6924489 which will become available in 6u25. I'll chase up with orig. submitter to verify then.
11-03-2011

WORK AROUND N/A
21-10-2010