Path: csiph.com!usenet.pasdenom.info!aioe.org!eternal-september.org!feeder.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Rhino Newsgroups: comp.lang.java.programmer Subject: Re: JavaFX beginner issue Date: Mon, 05 May 2014 11:29:27 -0400 Organization: A noiseless patient Spider Lines: 87 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Date: Mon, 5 May 2014 15:29:26 +0000 (UTC) Injection-Info: mx05.eternal-september.org; posting-host="fcde0965d19542f9cc4ec3c2459e228b"; logging-data="16498"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18F4a3F8p3sDiqQGSiHOlOVm5B9S7MxqSo=" User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.5.0 In-Reply-To: X-Antivirus-Status: Clean X-Antivirus: avast! (VPS 140505-0, 2014-05-05), Outbound message Cancel-Lock: sha1:4M84MeI3+xIuqAbI1tsIf/vYWMc= Xref: csiph.com comp.lang.java.programmer:28373 On 2014-05-05 1:53 AM, Wayne wrote: > On 5/4/2014 11:25 PM, Rhino wrote: >> I'm dabbling with JavaFX in NetBeans 8.0 and am trying to run a jar as a Java Web >> Start application. When I double-click on the HTML file created by NetBeans, I get: >> ====================================================================== >> Application Blocked by Security Settings >> >> Name: fxswingtest01.FxSwingTest01 >> Location: file:// >> Your security settings have blocked a self-signed application from running >> ======================================================================= >> >> What do I need to do to resolve this situation? I assume I need to give Java >> permission to run this application but I'm not sure how or where to do it and the >> tutorial I'm using didn't think to include this information.... >> > > You can set the security level to its lowest setting of "medium" > in the Java control panel. Or, also from the control panel, > you can white-list various locations such as "http://localhost/", > "https://localhost/", and "file:///". (You will get warning when > adding http or file protocol URLs, but you can ignore those for > localhost.) > > Or you can obtain a signing certificate and sign your code. > Thanks Wayne, I think we're heading in the right direction but I need some more detail.... I've tried adding all of these entries to the white-list in the Security tab of the Java Control Panel: http://localhost/ https://localhost/ http://127.0.0.1/ https:/127.0.0.1/ file:///C:/Users/rhino_000/Documents/NetBeans/HelloWorld/dist/HelloWorld.html file:///C:/Users/rhino_000/Documents/NetBeans/HelloWorld/dist/HelloWorld.jnlp I'm running Windows 8.1. When I double-click on the HelloWorld.jar in File Explorer here on the laptop, the application launches just fine. When I right-click on the HTML file and open it in Firefox, the Test Page for HelloWorld shows a "loading" animation that just keeps spinning and spinning and spinning but never gets done. When I right-click on the JNLP file in File Explorer, I get the Web Start "Java ..." splash screen, then I'm back to the error message I reported in my initial post in this thread. Hmm. I just added the following to the white-list: file:// Now, when I right-click on the JNLP file and choose Open With Java Web Start Launcher, it actually launches without the error message! However, right-clicking on the HTML file and opening it in Firefox works no better than it did before. Just for the heck of it, I uploaded the whole dist folder to a remote server and tried to access the HTML page: I get the same error as I do on my local hard drive in File Explorer. When I tried to open the JNLP file on the remote server, the browser asked me which application I wanted to use and I chose Java Web Start Launcher and got this: ===================================================================== Application Error General Exception Name: helloworld.HelloWorld ExitException[3]com.sun.deploy.net.FailedDownloadException: Unable to load resource: file:/C/Users/RHINO_~1/AppData/Local/Temp/HelloWorld.jar at sun.plugin2.applet.JNLP2Manager.downloadResources(Unknown Source) at sun.plugin2.applet.JNLP2Manager.prepareLaunchFile(Unknown Source) at sun.plugin2.applet.JNLP2Manager.loadJarFiles(Unknown Source) at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown Source) at java.lang.Thread.run(Unknown Source) ========================================================================== Why is it looking for a resource on my hard drive when I'm running it on a remote server? How do I fix this? -- Rhino