JDK-7196009 : SunPkcs11 provider fails to parse config path containing parenthesis
  • Type: Bug
  • Component: security-libs
  • Sub-Component: javax.crypto:pkcs11
  • Affected Version: 6u31
  • Priority: P3
  • Status: Closed
  • Resolution: Fixed
  • OS: windows_7
  • CPU: x86
  • Submitted: 2012-09-04
  • Updated: 2015-02-11
  • Resolved: 2013-05-16
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 7 JDK 8
7u80Fixed 8 b91Fixed
Related Reports
Duplicate :  
Relates :  
Description
FULL PRODUCT VERSION :
JRE 1.6.0_26

ADDITIONAL OS VERSION INFORMATION :
Windows Vista 64bit, Windows 7 64bit

A DESCRIPTION OF THE PROBLEM :
Since Java 1.6.0_26 sun.security.pkcs11.Config.java ensures that the path to the configuration file is passed as absolute path in order to "prevent the DLL preloading attack".

On Windows 64bit systems the path to the configuration file may contain parenthesis which is an unsupported token. In the bug report #6581254 a workaround was proposed: use Windows short paths.

This first failed because of the not supported tilde '~' token. But was fixed in the bug report #2196737 in the release 7(b126) .

It seems to me that the bug report #6581254 is assumed to be fixed with the release 7(b126) . But this is not the case! One can use Windows short paths as a workaround but this does not solve the problem.The trouble with this work around is to find the correct Windows short path. In my application I ended up trying the short paths "PROGRA~1" ... to "PROGRA~9". And this only works if the application is installed in the Program Files folder. If the user uses another path with parenthesis this workaround will not work.

Please have this bug fixed.

Sorry for creating another bug report. But I could not find out how to add a comment to an existing bug report. According to the documentation of the bug database there should be a text area at the end of the bug report. But there is none...



REGRESSION.  Last worked in version 6u31


REPRODUCIBILITY :
This bug can be reproduced always.

CUSTOMER SUBMITTED WORKAROUND :
Use Windows short paths.

Comments
No issues in the recent core-libs nightly detected. SQE OK to take the fix to PSU15_02.
06-02-2015

Is a backport to jdk6 needed?
05-02-2015

Provider/ConfigShortPath.java passed in B91 and after, failed in B90 and before version. Test machine: Linux jsn-vw1-00-vm1
19-06-2013

Removing the regression keyword since SunPKCS11 provider never have allowed parenthesis in earlier releases. So, this is not a regression.
03-04-2013