<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
<br>
<br>
Signing is pretty straightforward, and gives you full access to the
local machine.<br>
<br>
I can offer pointers on doing that, since I've recently used it in a
project.<br>
<br>
Note that I've had mixed results with getting updates to propogate
nicely - sometimes Java Webstart will just not for a while (several
hours) notice that there is an update on the server for quite some time.<br>
<br>
Regards, Noel.<br>
<br>
The relevant part of my ANT build script looks like:<br>
<br>
<!-- <br>
This produces a repacked JAR file, which is smaller and thus<br>
less to download.<br>
--><br>
<target name="packAndSign" description=""><br>
<copy tofile="webapp/jws/allInOne.tmp.jar"
file="webapp/jws/allInOne.jar"/><br>
<!-- rearrange the JAR so that signing does not get messed
up --><br>
<exec dir="webapp/jws" executable="pack200"><br>
<arg line="--repack"/><br>
<arg line="allInOne.tmp.jar"/><br>
</exec><br>
<!-- sign the jar --><br>
<signjar<br>
alias="myself" <br>
keystore="etc/myKeyStore"<br>
storePass="password"><br>
<fileset dir="webapp/jws"
includes="allInOne.tmp.jar"/><br>
</signjar><br>
<!-- now compress the JAR --><br>
<exec dir="webapp/jws" executable="pack200"><br>
<arg line="allInOne.jar.pack.gz"/><br>
<arg line="allInOne.tmp.jar"/><br>
</exec><br>
<!-- delete the temporary file --><br>
<delete file="webapp/jwsallInOne.tmp.jar"/><br>
</target><br>
<br>
Stefan Baebler wrote:
<blockquote cite="mid4655361C.7030102@gmail.com" type="cite">Chris
Fleming wrote:
<br>
<blockquote type="cite">The best way to do this would be through java
webstart... (<a class="moz-txt-link-freetext" href="http://java.sun.com/products/javawebstart/overview.html">http://java.sun.com/products/javawebstart/overview.html</a>)
<br>
</blockquote>
I like the idea, so I wrote the attached josm.jnlp file, added mime
type to my local apache
<br>
AddType application/x-java-jnlp-file .jnlp
<br>
clicked on the file in my web browser. It got recognized as an Java
application, tried to launch, but failed at MainApplication.java, line
64, some issue with permissions (stacktrace below*). It seems that code
needs to be modified to require less permisions (not using local files,
becoming less useful).
<br>
<br>
Otherwise, adding
<br>
<security>
<br>
<all-permissions/>
<br>
</security>
<br>
it complained that jar needs to be signed for that.
<br>
<br>
Hope it helps.
<br>
<br>
greets,
<br>
Stefan
<br>
<br>
*full stacktrace of the first exception:
<br>
java.security.AccessControlException: access denied
(java.lang.RuntimePermission setDefaultUncaughtExceptionHandler)
<br>
at java.security.AccessControlContext.checkPermission(Unknown
Source)
<br>
at java.security.AccessController.checkPermission(Unknown Source)
<br>
at java.lang.SecurityManager.checkPermission(Unknown Source)
<br>
at java.lang.Thread.setDefaultUncaughtExceptionHandler(Unknown
Source)
<br>
at
org.openstreetmap.josm.gui.MainApplication.main(MainApplication.java:64)
<br>
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
<br>
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
<br>
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
<br>
at java.lang.reflect.Method.invoke(Unknown Source)
<br>
at com.sun.javaws.Launcher.executeApplication(Unknown Source)
<br>
at com.sun.javaws.Launcher.executeMainClass(Unknown Source)
<br>
at com.sun.javaws.Launcher.doLaunchApp(Unknown Source)
<br>
at com.sun.javaws.Launcher.run(Unknown Source)
<br>
at java.lang.Thread.run(Unknown Source)
<br>
<pre wrap="">
<hr size="4" width="90%">
_______________________________________________
dev mailing list
<a class="moz-txt-link-abbreviated" href="mailto:dev@openstreetmap.org">dev@openstreetmap.org</a>
<a class="moz-txt-link-freetext" href="http://lists.openstreetmap.org/cgi-bin/mailman/listinfo/dev">http://lists.openstreetmap.org/cgi-bin/mailman/listinfo/dev</a>
</pre>
</blockquote>
<br>
<br><br><br><hr><font size="-2" color=808080>Disclaimer: <a href="http://www.peralex.com/disclaimer.html">http://www.peralex.com/disclaimer.html</a><br><br>
</body>
</html>