Home » Eclipse Projects » Eclipse Platform » Problem launching eclipse after using pack200 compression
| Problem launching eclipse after using pack200 compression [message #316585] |
Wed, 13 June 2007 11:00  |
Eclipse User |
|
|
|
Hello,
For previous Eclipse SDK versions, we have used pack200 to make
redistribution packages smaller. However, now that the jars in the
eclipse 3.3 SDK are being signed, the pack200/unpack process seems to be
causing problems.
When we try to launch Eclipse 3.3 RC3 that has been unpacked using
pack200, we get the following exception:
ava.lang.SecurityException: SHA1 digest error for
org/eclipse/equinox/launcher/
JNIBridge.class
at
sun.security.util.ManifestEntryVerifier.verify(ManifestEntry Verifier.
java:196)
at java.util.jar.JarVerifier.processEntry(JarVerifier.java:201)
at java.util.jar.JarVerifier.update(JarVerifier.java:188)
at
java.util.jar.JarVerifier$VerifierStream.read(JarVerifier.ja va:403)
at sun.misc.Resource.getBytes(Resource.java:77)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:256)
at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268 )
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319 )
java.lang.SecurityException: SHA1 digest error for
org/eclipse/equinox/launcher/
Main.class
at
sun.security.util.ManifestEntryVerifier.verify(ManifestEntry Verifier.
java:196)
at java.util.jar.JarVerifier.processEntry(JarVerifier.java:201)
at java.util.jar.JarVerifier.update(JarVerifier.java:188)
at
java.util.jar.JarVerifier$VerifierStream.read(JarVerifier.ja va:403)
at sun.misc.Resource.getBytes(Resource.java:77)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:256)
at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268 )
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319 )
Any ideas how to use pack and unpack the Eclispe SDK jars using pack200
compression without causing the SHA1 digest error?
Thanks in advance,
Greg
|
|
|
| Re: Problem launching eclipse after using pack200 compression [message #316592 is a reply to message #316585] |
Wed, 13 June 2007 12:12   |
Eclipse User |
|
|
|
Hi,
I using following properties, seems fine:
boolean signed = (jarFile.getEntry("META-INF/ECLIPSE.SF") != null);
Packer packer = Pack200.newPacker();
Map p = packer.properties();
if (signed) {
p.put(Packer.EFFORT, "4");
} else {
p.put(Packer.SEGMENT_LIMIT, "-1");
p.put(Packer.MODIFICATION_TIME, Packer.LATEST);
p.put(Packer.DEFLATE_HINT, Packer.TRUE);
if (strip) {
p.put(Packer.CODE_ATTRIBUTE_PFX + "LineNumberTable", Packer.STRIP);
p.put(Packer.CODE_ATTRIBUTE_PFX + "LocalVariableTable", Packer.STRIP);
p.put(Packer.CODE_ATTRIBUTE_PFX + "SourceFile", Packer.STRIP);
}
}
Eric Suen
|
|
|
| Re: Problem launching eclipse after using pack200 compression [message #316650 is a reply to message #316592] |
Thu, 14 June 2007 09:17   |
Eclipse User |
|
|
|
The Eclipse jars were all conditioned (pack/unpack) and signed using the
JarProcessor tool that is part of org.eclipse.update.core.
This tool will recursively process nested jars as well. I would recommend using
this tool to do both the packing and unpacking. Update itself uses it at
runtime to unpack pack.gz files downloaded from update sites.
See the wiki pages for some info:
http://wiki.eclipse.org/index.php/Update_Site_Optimization
http://wiki.eclipse.org/index.php/Pack200
One key thing to note is that Eclipse is conditioned using a default effort
level of 4, it is probably a good idea to do the packing with this effort as
well. You can look at the /META-INF/eclipse.inf file in eclipse jars to see the
arguments used to condition the jar.
-Andrew
Eric Suen wrote:
> Hi,
>
> I using following properties, seems fine:
>
> boolean signed = (jarFile.getEntry("META-INF/ECLIPSE.SF") != null);
> Packer packer = Pack200.newPacker();
> Map p = packer.properties();
> if (signed) {
> p.put(Packer.EFFORT, "4");
> } else {
> p.put(Packer.SEGMENT_LIMIT, "-1");
> p.put(Packer.MODIFICATION_TIME, Packer.LATEST);
> p.put(Packer.DEFLATE_HINT, Packer.TRUE);
> if (strip) {
> p.put(Packer.CODE_ATTRIBUTE_PFX + "LineNumberTable", Packer.STRIP);
> p.put(Packer.CODE_ATTRIBUTE_PFX + "LocalVariableTable", Packer.STRIP);
> p.put(Packer.CODE_ATTRIBUTE_PFX + "SourceFile", Packer.STRIP);
> }
> }
>
> Eric Suen
>
>
Greg Amerson wrote:
> Hello,
>
> For previous Eclipse SDK versions, we have used pack200 to make
> redistribution packages smaller. However, now that the jars in the
> eclipse 3.3 SDK are being signed, the pack200/unpack process seems to be
> causing problems.
>
> When we try to launch Eclipse 3.3 RC3 that has been unpacked using
> pack200, we get the following exception:
>
> ava.lang.SecurityException: SHA1 digest error for
> org/eclipse/equinox/launcher/
> JNIBridge.class
> at
> sun.security.util.ManifestEntryVerifier.verify(ManifestEntry Verifier.
> java:196)
> at java.util.jar.JarVerifier.processEntry(JarVerifier.java:201)
> at java.util.jar.JarVerifier.update(JarVerifier.java:188)
> at
> java.util.jar.JarVerifier$VerifierStream.read(JarVerifier.ja va:403)
> at sun.misc.Resource.getBytes(Resource.java:77)
> at java.net.URLClassLoader.defineClass(URLClassLoader.java:256)
> at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
> at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
> at java.security.AccessController.doPrivileged(Native Method)
> at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268 )
> at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
> at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319 )
> java.lang.SecurityException: SHA1 digest error for
> org/eclipse/equinox/launcher/
> Main.class
> at
> sun.security.util.ManifestEntryVerifier.verify(ManifestEntry Verifier.
> java:196)
> at java.util.jar.JarVerifier.processEntry(JarVerifier.java:201)
> at java.util.jar.JarVerifier.update(JarVerifier.java:188)
> at
> java.util.jar.JarVerifier$VerifierStream.read(JarVerifier.ja va:403)
> at sun.misc.Resource.getBytes(Resource.java:77)
> at java.net.URLClassLoader.defineClass(URLClassLoader.java:256)
> at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
> at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
> at java.security.AccessController.doPrivileged(Native Method)
> at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268 )
> at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
> at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319 )
>
>
> Any ideas how to use pack and unpack the Eclispe SDK jars using pack200
> compression without causing the SHA1 digest error?
>
> Thanks in advance,
> Greg
|
|
| |
| Re: Problem launching eclipse after using pack200 compression [message #316832 is a reply to message #316650] |
Tue, 19 June 2007 15:55  |
Eclipse User |
|
|
|
Hey Andrew,
I have written a couple of pack/unpack scripts that use the JarProcessor
tool from the o.e.update.core plugin. However, I had a very hard time
getting a pack.properties file that included pack.excludes/sign.excludes
statements to actually work. I am trying to run JarProcessor on a
directory and I never got the pack.excludes to be honored. However, if
I took the same pack.properties and zipped up my directory and pointed
the JarProcessor to the zip file, then it would work as expected.
I read some about this difference between directory and zip handling of
pack.properties but I'm still a little unsure what the current status is.
Any ideas?
Thanks for your time,
Greg
Andrew Niefer wrote:
> The Eclipse jars were all conditioned (pack/unpack) and signed using the
> JarProcessor tool that is part of org.eclipse.update.core.
>
> This tool will recursively process nested jars as well. I would
> recommend using this tool to do both the packing and unpacking. Update
> itself uses it at runtime to unpack pack.gz files downloaded from update
> sites.
>
> See the wiki pages for some info:
> http://wiki.eclipse.org/index.php/Update_Site_Optimization
> http://wiki.eclipse.org/index.php/Pack200
>
> One key thing to note is that Eclipse is conditioned using a default
> effort level of 4, it is probably a good idea to do the packing with
> this effort as well. You can look at the /META-INF/eclipse.inf file in
> eclipse jars to see the arguments used to condition the jar.
>
> -Andrew
> Eric Suen wrote:
>> Hi,
>>
>> I using following properties, seems fine:
>>
>> boolean signed = (jarFile.getEntry("META-INF/ECLIPSE.SF") != null);
>> Packer packer = Pack200.newPacker();
>> Map p = packer.properties();
>> if (signed) {
>> p.put(Packer.EFFORT, "4");
>> } else {
>> p.put(Packer.SEGMENT_LIMIT, "-1");
>> p.put(Packer.MODIFICATION_TIME, Packer.LATEST);
>> p.put(Packer.DEFLATE_HINT, Packer.TRUE);
>> if (strip) {
>> p.put(Packer.CODE_ATTRIBUTE_PFX + "LineNumberTable", Packer.STRIP);
>> p.put(Packer.CODE_ATTRIBUTE_PFX + "LocalVariableTable",
>> Packer.STRIP);
>> p.put(Packer.CODE_ATTRIBUTE_PFX + "SourceFile", Packer.STRIP);
>> }
>> }
>>
>> Eric Suen
>>
>>
> Greg Amerson wrote:
> > Hello,
> >
> > For previous Eclipse SDK versions, we have used pack200 to make
> > redistribution packages smaller. However, now that the jars in the
> > eclipse 3.3 SDK are being signed, the pack200/unpack process seems to be
> > causing problems.
> >
> > When we try to launch Eclipse 3.3 RC3 that has been unpacked using
> > pack200, we get the following exception:
> >
> > ava.lang.SecurityException: SHA1 digest error for
> > org/eclipse/equinox/launcher/
> > JNIBridge.class
> > at
> > sun.security.util.ManifestEntryVerifier.verify(ManifestEntry Verifier.
> > java:196)
> > at java.util.jar.JarVerifier.processEntry(JarVerifier.java:201)
> > at java.util.jar.JarVerifier.update(JarVerifier.java:188)
> > at
> > java.util.jar.JarVerifier$VerifierStream.read(JarVerifier.ja va:403)
> > at sun.misc.Resource.getBytes(Resource.java:77)
> > at java.net.URLClassLoader.defineClass(URLClassLoader.java:256)
> > at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
> > at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
> > at java.security.AccessController.doPrivileged(Native Method)
> > at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
> > at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
> > at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268 )
> > at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
> > at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319 )
> > java.lang.SecurityException: SHA1 digest error for
> > org/eclipse/equinox/launcher/
> > Main.class
> > at
> > sun.security.util.ManifestEntryVerifier.verify(ManifestEntry Verifier.
> > java:196)
> > at java.util.jar.JarVerifier.processEntry(JarVerifier.java:201)
> > at java.util.jar.JarVerifier.update(JarVerifier.java:188)
> > at
> > java.util.jar.JarVerifier$VerifierStream.read(JarVerifier.ja va:403)
> > at sun.misc.Resource.getBytes(Resource.java:77)
> > at java.net.URLClassLoader.defineClass(URLClassLoader.java:256)
> > at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
> > at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
> > at java.security.AccessController.doPrivileged(Native Method)
> > at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
> > at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
> > at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268 )
> > at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
> > at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319 )
> >
> >
> > Any ideas how to use pack and unpack the Eclispe SDK jars using pack200
> > compression without causing the SHA1 digest error?
> >
> > Thanks in advance,
> > Greg
|
|
|
Goto Forum:
Current Time: Sun Nov 09 18:36:28 EST 2025
Powered by FUDForum. Page generated in 0.03639 seconds
|