United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: 7151711 Http Basic Authentication dialog shown twice and does not work when launch JNLP applet from shortcut
7151711 : Http Basic Authentication dialog shown twice and does not work when launch JNLP applet from shortcut

Details
Type:
Bug
Submit Date:
2012-03-07
Status:
Resolved
Updated Date:
2012-06-13
Project Name:
JDK
Resolved Date:
2012-06-13
Component:
deploy
OS:
generic
Sub-Component:
deployment_toolkit
CPU:
generic
Priority:
P3
Resolution:
Fixed
Affected Versions:
7u6
Fixed Versions:
8

Related Reports
Backport:
Relates:

Sub Tasks

Description
Shadowing of JIRA: http://javafx-jira.kenai.com/browse/RT-16847

Steps to reproduce:
1. Invoke javaws -uninstall to clear cache or clear cache using Java control panel 
2. Make sure that pop-up blocker is turned off and set browser TAB settings to always open new page inside new window 
3. Open http://mossad.us.oracle.com:8080/basicAuth/tests/fxfeaturesTest/fxfeaturesTest/html/ShowDocumAuthSCJNLPTest.html inside new browser window 
4. There should be Authenticated pop-up from browser. Enter credentials as User: jituB and password: jitu20 
5. Click on "Webstart: click to launch this app as webstart" 
6. There should be Authenticated pop-up from Java. Enter credentials as User: jituB and password: jitu20 
7. There should be prompt to create shortcut. Allow to create shortcut and make sure that shorcut with name"ShowDocumAuthSCTest" is getting created 
8. JNLP Application should get loaded fine 
9. Now close the application and click on shorctut "ShowDocumAuthSCTest". Make sure that application is getting launched 
10. Wait untill the Authenticated pop-up shows up. 
11. Enter credentials as User: jituB and password: jitu20 
Expect: 
12. The applicaiton should get launched successfully. 
As a result: 
12. Now the Authenticated pop-up shows up again with

                                    

Comments
EVALUATION

Fixed as describe in webrev:
http://sa.us.oracle.com/mail-archive/7151711-deployment
Changeset:
http://closedjdk.us.oracle.com/jdk8/deploy/deploy/rev/96733fcb1284
                                     
2012-06-11
EVALUATION

When we launch JNLP applet-desc using JNLPViewer, Applet2Environment.initialize() replace ServiceManager.service with an instanceof Applet2BrowserService which is based on essentially NoopAppletExecutionContext (DisconnectedExecutionContext is essentially the same with regards to platform authentication services).  This execution context, basically return null CredentialManager, causing NPE and  authentication failure, hence 401 return code on update check.

One possible fix is to preserve the initial ServiceManager.service and use it as fallback for platform services calls on DisconnectedExecutionContext.

The NPE in JNLPException also need to be fix, but is not essential to the failure.
                                     
2012-03-07



Hardware and Software, Engineered to Work Together