Description of problem: Openjdk does not load any java applet from the internet. Local java applets work fine. I am behind an authenticated proxy which i need to access external sites/internet. I get the following error messages on the terminal ''' net.sourceforge.jnlp.LaunchException: Fatal: Initialization Error: Could not initialize applet. at net.sourceforge.jnlp.Launcher.createApplet(Launcher.java:472) at net.sourceforge.jnlp.Launcher.getApplet(Launcher.java:418) at net.sourceforge.jnlp.Launcher$TgThread.run(Launcher.java:597) Caused by: java.lang.NullPointerException at net.sourceforge.jnlp.Launcher.createApplet(Launcher.java:458) ... 2 more Caused by: java.lang.NullPointerException at net.sourceforge.jnlp.Launcher.createApplet(Launcher.java:458) at net.sourceforge.jnlp.Launcher.getApplet(Launcher.java:418) at net.sourceforge.jnlp.Launcher$TgThread.run(Launcher.java:597) java.lang.NullPointerException at net.sourceforge.jnlp.NetxPanel.runLoader(NetxPanel.java:97) at sun.applet.AppletPanel.run(AppletPanel.java:380) at java.lang.Thread.run(Thread.java:636) java.lang.NullPointerException at sun.applet.AppletPanel.run(AppletPanel.java:430) at java.lang.Thread.run(Thread.java:636) ''' This message is repeated a lot of times, probably once for each refresh of the page i do. The sun java applet works fine (loads too slow, asks for proxy password dialog when it loads the first applet in a session). Version-Release number of selected component (if applicable): java-1.6.0-openjdk-plugin-1.6.0.0-9.b14.fc10.i386 How reproducible: Always Steps to Reproduce: 1. Open any web page with a java applet ( http://www.java.com/en/download/help/testvm.xml ). Actual results: Grey rectangle appears where the applet should be, firefox statusbar shows "starting applet...". It stays in that state. Expected results: The applet should be displayed properly Additional info: I am behind an authenticated proxy to access internet. Local applets on my computer seem to work fine. Same problem exists with epiphany browser
NetX (WebStart) and the the plugin do not support proxy at the moment. I will take a look into this on Monday.
Thanks for looking into it. If NetX (WebStart) and the plugin do not support proxies at the moment then i suppose it may take a long time. In the meanwhile is there any hack we could use to workaround the problem. I tried putting these into the main method in the file 'sun.applet.PluginMain' (java-1.6.0-openjdk-1.6.0.0-9.b14.fc10.src/icedtea6-1.4/plugin/icedtea/sun/applet in the source rpm) and adding to the system rt.jar: " Properties props = System.getProperties(); props.put("http.proxyHost", "myproxy.site.com"); props.put("http.proxyPort", "80"); props.put("http.proxyUser", "user"); props.put("http.proxyPassword", "pwd"); System.setProperties(props); " but still it doesnt work. Is there anything else i could do. Like setting the URL.setURLStreamHandlerFactory() or something else so that it may work (need not be a good permanent soln, a temporary hack with hardcoded values will be fine) Thanks again, and i'll be glad for any further information/testing which i could do.
Putting that in the main method should have worked. How exactly did you make the modifications and rebuild?
Okay, I know why it is not working. You are using an authenticated proxy you said? There is no way you can set the user and password for it via system properties. The Java api only allows host and port specification: http://java.sun.com/j2se/1.5.0/docs/guide/net/properties.html
Ya i got that to work using Authenticator class. It was a hack for my specific values so now i'm trying to get it to use the http_proxy env variable. It was easy actually. Donno why no one ever implemented it.
Created attachment 333844 [details] A diff of the file i made to implement http proxy support in the plugin A diff of the file i made to implement http proxy support in the plugin
Created attachment 333847 [details] PluginMain.java file with primitive proxy support I dont know if diffs are any useful so i'm rather sending the exact file which i made. I've implemented primitive support for taking proxy settings from environment variables for http and https. It should work well until this feature is properly implemented. I've tested it in epiphany and firefox for both local applets (file://) and internet applets (http://). However i'm not sure if it'll work with http://localhost applets (it doesn't handle proxy exceptions for now - "no_proxy" environment variable). I'd be glad if this feature made it fast to the plugin. Thanks
java-1.6.0-openjdk-1.6.0.0-18.b16.fc10 has been submitted as an update for Fedora 10. http://admin.fedoraproject.org/updates/java-1.6.0-openjdk-1.6.0.0-18.b16.fc10
java-1.6.0-openjdk-1.6.0.0-22.b16.fc11 has been submitted as an update for Fedora 11. http://admin.fedoraproject.org/updates/java-1.6.0-openjdk-1.6.0.0-22.b16.fc11
java-1.6.0-openjdk-1.6.0.0-22.b16.fc11 has been pushed to the Fedora 11 stable repository. If problems still persist, please make note of it in this bug report.
java-1.6.0-openjdk-1.6.0.0-18.b16.fc10 has been pushed to the Fedora 10 stable repository. If problems still persist, please make note of it in this bug report.