United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
JDK-6886430 : User homedir is not a valid directory

Details
Type:
Bug
Submit Date:
2009-09-29
Status:
Closed
Updated Date:
2011-02-16
Project Name:
JDK
Resolved Date:
2010-06-19
Component:
deploy
OS:
windows_2003
Sub-Component:
plugin
CPU:
x86
Priority:
P3
Resolution:
Fixed
Affected Versions:
6u10
Fixed Versions:
6u21 (b01)

Related Reports
Backport:

Sub Tasks

Description
FULL PRODUCT VERSION :
JRE 1.6.0_11

ADDITIONAL OS VERSION INFORMATION :
Windows 2003

A DESCRIPTION OF THE PROBLEM :
The following problem occured in the context of a large e-government website.
We don't rely on simple user/password authentification, instead we use
public/private key authentication with java applets.
In the login applet we are evaluating user.home and search for a login keystore.

Some users reported that the login applet stopped working after upgrading from jre 1.6.0_07 to 1.6.0_11.

After deactivating the Next Generation Java-Plugin for 1.6.0_11 the problem disappeared and everything
worked as usual.

We tracked down the problem to a slight difference in the system properties between the Next Generation
Java Plugin and the Classic Plugin (both with jre 1.6.0_11):

In some cases the Next Generation Plugin would set user.home to a UNC network ressource.

A real-life example to demonstrate the differences between the Next Generation and the Classic Plugin:

Classic:
user.dir = \\s6077769\desktop
user.home = C:\Dokumente und Einstellungen\0077769BER0000000001
user.name = 0077769BER0000000001

Next Generation:
user.dir = \\s6077769\desktop
user.home = \\s6077769
user.name = 0077769BER0000000001

The value of "user.home" is expected to be a directory (according to http://java.sun.com/docs/books/tutorial/essential/environment/sysprop.html).

Unlike "C:\Dokumente und Einstellungen\0077769BER0000000001" The UNC network ressource "user.home = \\s6077769"
is not recognized as a directory by java (File.isDirectory()==false)

user.home MUST be a directory

We consider this to be a major bug, because the only known workaround is abandon the Next Generation Java-Plugin and switch back to the Classic Plugin


EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
File.isDirectory() on user.home is always true.
ACTUAL -
File.isDirectory() on user.home sometimes is false.

REPRODUCIBILITY :
This bug can be reproduced always.

CUSTOMER SUBMITTED WORKAROUND :
switch back to the Classic Plugin

Release Regression From : 6u7
The above release value was the last known release where this 
bug was not reproducible. Since then there has been a regression.

                                    

Comments
SUGGESTED FIX

webrev: http://sa.sfbay.sun.com/projects/deployment_data/6u20/6886430.2
                                     
2010-02-26
EVALUATION

The new plugin relies on the java launcher to set the user.home property which will be set to the UNC network resource. A fix will be for the windows platform, set the user.home property to the USERPROFILE env. setting.
                                     
2010-02-19



Hardware and Software, Engineered to Work Together