Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4651347

JCK1.4: api/javax_security/auth/x500/X500Principal/serial/index.html#Input

XMLWordPrintable

    • x86, sparc
    • generic, linux, solaris_8, windows_98, windows_nt



      Name: icR10030 Date: 03/12/2002



      JDK : jdk1.4.1-b04, jre1.4.1-b04
      JCK : JCK1.4
      Platform[s] : RedHat Linux 7.1, Windows ME, Windows NT 4.0, Solaris 8 IA
      switch/Mode : -client -Xmixed, plugin for Netscape
      JCK test owner : http://javaweb.eng/jck/usr/owners.jto
      Failing Test : api/javax_security/auth/x500/X500Principal/serial/index.html#Input

      Java Object Serialization Specification reads:
      ..
      Each versioned class must identify the original class version for which it is capable of writing
      streams and from which it can read. For example, a versioned class must declare:
           private static final long serialVersionUID = 3487495895819393L;
      The stream-unique identifier is a 64-bit hash of the class name, interface class names, methods, and fields.
      ..

      The JCK1.4 api/javax_security/auth/x500/X500Principal/serial/index.html#Input
      supposes that serialVersionUID constant for the javax.security.auth.x500.X500Principal
      class is -500463348111345721, although in the build 04
      class serialVersionUID is 4901686772955173528.

      That is why the test fails.
      Please, note that the test passes in the build 03.

      Test source location:
      =====================
      /net/jdk/export/disk8/local.java/jck1.4/JCK-runtime-14/tests/api/javax_security/auth/x500/X500Principal/serial/InputTests.java

      jtr file location:
      ==================
      /net/jtgb4u4c.eng/export/sail15/results/hopper/b04/jck14/linux/redhat7.2_gnome_smp_plugin_ns6.2_linux-24/workDir/api/javax_security/auth/x500/X500Principal/serial/index_Input.jtr

      How to reproduce:
      =================
      Run the following script under RedHat Linux 7.1
      (probably, you need to change JCK and JAVA_HOME paths):
      --------Script START---------------------
      #!/bin/sh

      JCK=/net/jdk/export/disk8/local.java/jck1.4/JCK-runtime-14
      JDK=/net/jdk/export/disk8/local.java/jdk1.4.1/linux-i386
      export JCK
      export JDK

      $JDK/bin/java -version
      $JDK/bin/java -client -Xfuture -cp $JCK/classes -Djava.security.policy=$JCK/lib/jck.policy -Djava.security.auth.policy=$JCK/lib/java.auth.policy -Djava.security.auth.login.config=$JCK/lib/java.login.config javasoft.sqe.tests.api.javax.security.auth.x500.X500Principal.serial.InputTests
      --------Script END----------------------

      Test output:
      ============
      java version "1.4.1-beta"
      Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.1-beta-b04)
      Java HotSpot(TM) Client VM (build 1.4.1-beta-b04, mixed mode)
      serial2002: Failed. FAILED
      Checking for JDK Version : 1.4
      Creating StreamObject from spec
      Setting the value of serial fields
      Converting the StreamObject to Object
      I/O error. Got exception:
      java.io.InvalidClassException: javax.security.auth.x500.X500Principal; local class incompatible: stream classdesc serialVersionUID = -500463348111345721, local class serialVersionUID = 4901686772955173528
              at java.io.ObjectStreamClass.initNonProxy(ObjectStreamClass.java:454)
              at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1511)
              at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1425)
              at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1616)
              at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1264)
              at java.io.ObjectInputStream.readObject(ObjectInputStream.java:322)
              at javasoft.sqe.serial.util.Convert.streamObjectToObject(Convert.java:60)
              at javasoft.sqe.tests.api.javax.security.auth.x500.X500Principal.serial.InputTests.serial2002(InputTests.java:92)
              at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
              at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
              at java.lang.reflect.Method.invoke(Method.java:324)
              at javasoft.sqe.javatest.lib.MultiTest.invokeTestCase(MultiTest.java:397)
              at javasoft.sqe.javatest.lib.MultiTest.run(MultiTest.java:193)
              at javasoft.sqe.javatest.lib.MultiTest.run(MultiTest.java:125)
              at javasoft.sqe.tests.api.javax.security.auth.x500.X500Principal.serial.InputTests.main(InputTests.java:31)
      serial2002 failed.
      STATUS:Failed.tests: 1; failed: 1; first test case failure: serial2002

      Specific Machine Info:
      ======================
      Hostname: linux-12
      Os: RedHat Linux 7.1/GNOME


      ======================================================================

            Unassigned Unassigned
            ichesunw Iche Iche (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: