aspose file tools*
The moose likes JNLP and Web Start and the fly likes jnlp file error Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JNLP and Web Start
Bookmark "jnlp file error" Watch "jnlp file error" New topic
Author

jnlp file error

seema pal
Ranch Hand

Joined: Nov 17, 2005
Posts: 39
i am try to run jnlp file through java web start and i am signed all jar files
but it occours errors .the error given below.
"An error occurred while launching/running the application.
Title: ReloadEditor
Vendor: ReloadTools
Category: Launch File Error

JAR resources in JNLP file are not signed by same certificate."
Ed Ewing
Greenhorn

Joined: Aug 30, 2005
Posts: 29
Originally posted by seema pal:
"JAR resources in JNLP file are not signed by same certificate."


The error message above seems pretty clear to me. You are required to sign all of the jar files using the same jarsigning certificate.
j.g. jungman
Greenhorn

Joined: Jan 16, 2006
Posts: 2
When you will run the above JNLP, you will get the following Web Start exception:

JAR resources in JNLP file are not signed by same certificate

The reason for this is simple - one of the jar files that you are using was already signed by another party. Here is the way to find it:

jarsigner -certs -verbose -verify activation.jar

You will see a long list of certificates (one for each file). This means that this specific jar was signed by another party (Sun in our case). The solution for the problem is simple - put this jar in a separate JNLP and reference it in your main JNLP:

<?xml version="1.0" encoding="UTF-8"?>
<jnlp spec="1.0+" codebase="https://jaxb-workshop.dev.java.net/webstart/" href="activation.jnlp">
<information>
<title>Activation</title>
<vendor>Sun Microsystems, Inc.</vendor>
<offline-allowed/>
</information>
<offline-allowed/>
<resources>
<jar href="activation.jar"/>
</resources>
<component-desc/>
</jnlp>

As you can see, we don't ask for permissions, as this specific jar doesn't need them. Then, you reference this activation.jnlp in your main JNLP:

<?xml version="1.0" encoding="UTF-8"?>
<jnlp spec="1.0+" codebase="https://jaxb-workshop.dev.java.net/webstart/" href="wizard.jnlp">
<information>
<title>XJC Wizard</title>
<vendor>https://jaxb-workshop.dev.java.net/</vendor>
<description>Wizard frontend for XJC generator</description>
<description kind="short">Wizard frontend for XJC generator</description>
<offline-allowed/>
</information>
<offline-allowed/>
<security>
<all-permissions/>
</security>
<resources>
<j2se version="1.5+"/>
<jar href="jaxbw.jar"/>
<jar href="substance.jar"/>
<jar href="jaxb-api.jar"/>
<jar href="jaxb-impl.jar"/>
<jar href="jaxb-xjc.jar"/>
<jar href="jsr173_api.jar"/>
<extension name="activation" href="activation.jnlp"/>
</resources>
<application-desc main-class="org.jvnet.jaxbw.xjcfe.wizard.WizardMainFrame"/>
</jnlp>
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: jnlp file error