>>>>> "Mark" == Mark Wielaard <[EMAIL PROTECTED]> writes:

Mark> Hi,
Mark> On Mon, 2004-11-08 at 23:46, Steven Augart wrote:
>> >  development: Failed in SPECjbb2000
>> Another new problem, this time during class loading.  I'm CC'ing
>> this to the classpath list, since it probably points to a problem
>> in Classpath CVS head.
>> 
>> at java.util.jar.JarFile.verify(JarFile.java:669)
>> at java.util.jar.JarFile.readSignatures(JarFile.java:561)
>> at java.util.jar.JarFile.getEntry(JarFile.java:406)
>> at java.util.jar.JarFile.getJarEntry(JarFile.java:475)

Mark> I was just hunting this one down.
Mark> Attached is my first attempt.

Unfortunately, this is a different bug :(

The code checks if the signature file identifier is DSA or RSA, but
unfortunately leaves the Signature object 'null' if it is
neither. Which is odd; Steven, is this Jar file signed? Any chance I
could get some info about it, if it is? Like what algorithm signed it?

I'll check in the attached patch that fixes this.

Mark> It makes sure to not check the verified Map when the jar file is
Mark> explicitly opened with verify set to false. It also just
Mark> compares the value in the Map to Boolean.TRUE or Boolean.FALSE.

Mark> I am still thinking about synchronization issues.  It looks like
Mark> we need to be more careful about synchronization when
Mark> manipulating/reading the verified Map since a JarFile can
Mark> probably be accessed from multiple threads at once.

Eek, yeah, I didn't consider synchronization.

-- 
Casey Marshall || [EMAIL PROTECTED]
Index: java/util/jar/JarFile.java
===================================================================
RCS file: /cvsroot/classpath/classpath/java/util/jar/JarFile.java,v
retrieving revision 1.12
diff -u -B -b -r1.12 JarFile.java
--- java/util/jar/JarFile.java	7 Nov 2004 22:04:57 -0000	1.12
+++ java/util/jar/JarFile.java	9 Nov 2004 05:18:43 -0000
@@ -643,6 +643,12 @@
             else
               return;
           }
+	else
+	  {
+	    if (DEBUG)
+	      debug("unsupported signature algorithm: " + alg);
+	    return;
+	  }
       }
     catch (NoSuchAlgorithmException nsae)
       {
_______________________________________________
Classpath mailing list
[EMAIL PROTECTED]
http://lists.gnu.org/mailman/listinfo/classpath

Reply via email to