JDK-6306697 : PIT: CookieManager/TestCookieManager/TestCookieManager3 failed in Mustang PIT b47
  • Type: Bug
  • Component: core-libs
  • Sub-Component: java.net
  • Affected Version: 6
  • Priority: P2
  • Status: Closed
  • Resolution: Fixed
  • OS: generic,linux_redhat_3.0,windows_xp
  • CPU: generic,x86
  • Submitted: 2005-08-04
  • Updated: 2010-04-02
  • Resolved: 2006-03-17
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.
6 betaFixed
Related Reports
Duplicate :  
Duplicate :  
Duplicate :  
Relates :  
Relates :  
System Config.:
Mustang PIT b47, RHAS 3.0, Solaris S10, Suse AMD64, Windows XP

CookieManager/TestCookieManager/TestCookieManager3 failed in Mustang PIT b47.

Result directory:

According to developer, it's a jdk bug.
It might the same bug as headline/4447135 . Need more investigation.

EVALUATION This is not the bug of CookieManager feature, actually. It's caused by fix for 6274990. Below is the long story - the fix for 6181108 add a line to sun.net.www.ParseUtil: try { // if don't do this, URI may double escape path component path = decode(path); // <-- new line of code to fix 6181108 uri = new java.net.URI(protocol, auth, path, query, ref); } which do fix 6181108 and causes the regression 6274990, because decode(...) can't handle non UTF-8 string. Then comes the fix for 6274990: uri = url.toURI(); which fixs both 6181108 & 6274990, because url.toURI() utilizes single-constructor of URI class which never double-encode char sequence and can handle non UTF-8 string at the same time. But it lacks one unusual behavior of old sun.net.www.ParseUtil code: if (path != null && !(path.startsWith("/"))) path = "/" + path; which will construct an URI from an URL with empty path component has a path component of "/". A simple uri = url.toURI() won't behavior like this. This unexpected behavior change causes the cookie being rejected in path-match phase. Will fix this soon and add a regression test to ensure preserving the legacy behavior of sun.net.www.ParseUtil class.