5

I get this error when I try to open an specific .jnlp file:

net.sourceforge.jnlp.LaunchException: Fatal: Initialization Error: Could not initialize application. The application has not been initialized, for more information execute javaws from the command line.
    at net.sourceforge.jnlp.Launcher.createApplication(Launcher.java:813)
    at net.sourceforge.jnlp.Launcher.launchApplication(Launcher.java:532)
    at net.sourceforge.jnlp.Launcher$TgThread.run(Launcher.java:936)
Caused by: net.sourceforge.jnlp.LaunchException: Fatal: Application Error: Cannot grant permissions to unsigned jars. Application requested security permissions, but jars are not signed.
    at net.sourceforge.jnlp.runtime.JNLPClassLoader$SecurityDelegateImpl.getClassLoaderSecurity(JNLPClassLoader.java:2393)
    at net.sourceforge.jnlp.runtime.JNLPClassLoader.setSecurity(JNLPClassLoader.java:321)
    at net.sourceforge.jnlp.runtime.JNLPClassLoader.initializeResources(JNLPClassLoader.java:734)
    at net.sourceforge.jnlp.runtime.JNLPClassLoader.<init>(JNLPClassLoader.java:285)
    at net.sourceforge.jnlp.runtime.JNLPClassLoader.createInstance(JNLPClassLoader.java:357)
    at net.sourceforge.jnlp.runtime.JNLPClassLoader.getInstance(JNLPClassLoader.java:429)
    at net.sourceforge.jnlp.runtime.JNLPClassLoader.getInstance(JNLPClassLoader.java:403)
    at net.sourceforge.jnlp.Launcher.createApplication(Launcher.java:805)
    ... 2 more

that file is for access to Cisco ASA's ASDM and it had been working fine since always, untill yesterday... I'm using 4 more files like that one (cause I have 5 ASA's) and those are working great.

Can anybody helpme please?? Thanks in advance.

BR.


thanks to you too @ryekayo, here's what I get from the command line:

gaspar@gaspar-Lenovo-ideapad-310-15ISK ~ $ javaws https://192.168.0.5/admin/public/asdm.jnlp
OpenJDK 64-Bit Server VM warning: NewSize (1536k) is greater than the MaxNewSize (1024k). A new max generation size of 1536k will be used.
netx: Initialization Error: Could not initialize application. (Fatal: Application Error: Cannot grant permissions to unsigned jars. Application requested security permissions, but jars are not signed.)
net.sourceforge.jnlp.LaunchException: Fatal: Initialization Error: Could not initialize application. The application has not been initialized, for more information execute javaws from the command line.
    at net.sourceforge.jnlp.Launcher.createApplication(Launcher.java:813)
    at net.sourceforge.jnlp.Launcher.launchApplication(Launcher.java:532)
    at net.sourceforge.jnlp.Launcher$TgThread.run(Launcher.java:936)
Caused by: net.sourceforge.jnlp.LaunchException: Fatal: Application Error: Cannot grant permissions to unsigned jars. Application requested security permissions, but jars are not signed.
    at net.sourceforge.jnlp.runtime.JNLPClassLoader$SecurityDelegateImpl.getClassLoaderSecurity(JNLPClassLoader.java:2393)
    at net.sourceforge.jnlp.runtime.JNLPClassLoader.setSecurity(JNLPClassLoader.java:321)
    at net.sourceforge.jnlp.runtime.JNLPClassLoader.initializeResources(JNLPClassLoader.java:734)
    at net.sourceforge.jnlp.runtime.JNLPClassLoader.<init>(JNLPClassLoader.java:285)
    at net.sourceforge.jnlp.runtime.JNLPClassLoader.createInstance(JNLPClassLoader.java:357)
    at net.sourceforge.jnlp.runtime.JNLPClassLoader.getInstance(JNLPClassLoader.java:429)
    at net.sourceforge.jnlp.runtime.JNLPClassLoader.getInstance(JNLPClassLoader.java:403)
    at net.sourceforge.jnlp.Launcher.createApplication(Launcher.java:805)
    ... 2 more
DDiamond
  • 216
  • 2
  • 10
gasparmenendez
  • 63
  • 1
  • 2
  • 6
  • Have you tried running javaws from the command line? This can provide more info as stated by your stacktrace. – ryekayo May 30 '17 at 15:50
  • Probably, there was a java upgrade and the new runtime is no more compatible with this version. – DevOps May 30 '17 at 16:54
  • Also, the error message is pointing you at the problem: Cannot grant permissions to unsigned jars. Application requested security permissions, but jars are not signed. – DevOps May 30 '17 at 16:55
  • Also check for the Java control panel (javacpl.exe) but when I had the issue in the past, it was linked to a updated and more restrictive Java runtime – DevOps May 30 '17 at 16:57
  • thanks @DevOps, but if there was a java update, why are the other 4 files working fine?? besides, I can see the message is pointing to the error but how can I fix that??? and for the last, I'm working in Linux, so how can I call the Java Control Panel??? – gasparmenendez May 30 '17 at 17:20
  • Use the editing tools to add information to your post and to format it to be more readable. – Sven May 30 '17 at 20:19
  • @gasparmenendez mostly other are working because they are either using other (jar) files which are signed and allowed `Application requested security permissions, but jars are not signed`. On their do not perform operation with special privilege requiring a signed jar. – DevOps Jun 01 '17 at 15:38

2 Answers2

5

Copied this from an iDrac solution that I used to fix my Cisco ASDM issue and found that it worked.

https://velenux.wordpress.com/2017/06/07/workaround-for-javaws-jnpl-error-cannot-grant-permissions-to-unsigned-jars/

You are getting an error like:

net.sourceforge.jnlp.LaunchException: Fatal: Application Error: Cannot grant permissions to unsigned jars.

Quick workaround:

Find the java.security file. In my case it is located in /usr/lib/jvm/java-8-openjdk-amd64/jre/lib/security/java.security

Then find the row:

jdk.jar.disabledAlgorithms=MD2, MD5, RSA keySize < 1024

Comment it out, copy it, delete the MD5 string.

#jdk.jar.disabledAlgorithms=MD2, MD5, RSA keySize < 1024
jdk.jar.disabledAlgorithms=MD2, RSA keySize < 1024

Save the file. Try again. It should work.

Larry R. Irwin
  • 176
  • 1
  • 2
0

Download a previous version of Java runtime (like 1.7 or 1.6) and run it with this one. Location is at the bottom on the page at http://www.oracle.com/technetwork/java/javase/downloads/index.html

As state on the page :

WARNING: These older versions of the JRE and JDK are provided to help developers debug issues in older systems. They are not updated with the latest security patches and are not recommended for use in production.

In our case, you don't have any choice as Cisco is not providing updated signed jar to access your Cisco ASA.

To run it with old version, don't forget to provide full path like for windows

c:\tools\jdk1.6.0_95\bin\javaw.exe https://192.168.0.5/admin/public/asdm.jnlp 

or linux in your case

/opt/jdk1.6.0_67/bin/javaws https://192.168.0.5/admin/public/asdm.jnlp 
DevOps
  • 720
  • 5
  • 16
  • I'm a little bit disoriented here because I don't know java very much...the java's version I have installed is: **gaspar@gaspar-Lenovo-ideapad-310-15ISK / $ java -version openjdk version "1.8.0_131" OpenJDK Runtime Environment (build 1.8.0_131-8u131-b11-0ubuntu1.16.04.2-b11) OpenJDK 64-Bit Server VM (build 25.131-b11, mixed mode)** and in the link you sent me I can't find 1.6 or 1.7, from where can I download any of those versions?? – gasparmenendez Jun 02 '17 at 21:46
  • http://prntscr.com/ffa2cz then http://prntscr.com/ffa2hg then http://prntscr.com/ffa2sf – DevOps Jun 03 '17 at 00:11
  • sorry @DevOps, I already download and installed jdk-6u45-linux-x64.bin, but when I run the command I get the following: **gaspar@gaspar-Lenovo-ideapad-310-15ISK ~ $ /opt/jdk1.6.0_45/bin/javaws https://192.168.0.5/admin/public/asdm.jnlp bash: /opt/jdk1.6.0_45/bin/javaws: No existe el archivo o el directorio**... what I'm missing here?? – gasparmenendez Jun 07 '17 at 15:37
  • if you try `ls -la /opt/jdk1.6.0_45/bin/` what is the output ? This is to ensure it is available with right permissions. – DevOps Jun 07 '17 at 16:38
  • **gaspar@gaspar-Lenovo-ideapad-310-15ISK ~ $ ls -la /opt/jdk1.6.0_45/bin/ ls: no se puede acceder a '/opt/jdk1.6.0_45/bin/': No existe el archivo o el directorio**.... sorry, mi Linux is in Spanish, output says something like: directory doesn't exist – gasparmenendez Jun 07 '17 at 17:44
  • So if directory doesn't exist, either this Java is not installed here, or not installed at all. When you have installed jdk-6u45-linux-x64.bin, where did it installed it ? Could it be a permission issue at `/opt`or `/opt/jdk1.6.0_45` or `/opt/jdk1.6.0_45/bin/` preventing your user **gaspar** to access it ? – DevOps Jun 08 '17 at 14:43
  • We did it my friend @DevOps!! was a path problem.... Thank you very much!! – gasparmenendez Jun 08 '17 at 16:32
  • After it worked fine for about a month, now it doesn't anymore...I was using jdk1.6.0_45 and now downloaded jdk1.7.0_80 but it's the same. I get "Aplication Error" and a red circle with a white exclamation mark inside...can anybody help me please??? – gasparmenendez Jul 15 '17 at 16:43