/hg/release/icedtea6-1.8: 6 new changesets

andrew at icedtea.classpath.org andrew at icedtea.classpath.org
Tue Feb 14 23:45:15 PST 2012


changeset 08e7c18e12c1 in /hg/release/icedtea6-1.8
details: http://icedtea.classpath.org/hg/release/icedtea6-1.8?cmd=changeset;node=08e7c18e12c1
author: Andrew John Hughes <ahughes at redhat.com>
date: Fri Feb 10 11:25:13 2012 +0000

	Add 2012/02/14 security patches.

	2012-02-08 Omair Majid <omajid at redhat.com>

	 * NEWS: Update with security fixes.
		* Makefile.am (SECURITY_PATCHES): Add security patches.
	(SPECIAL_SECURITY_PATCH): Add new variable.
	(ICEDTEA_PATCHES): Add security patch that epends on backport.
		* patches/security/20120214/7082299.patch,
		* patches/security/20120214/7088367.patch,
		* patches/security/20120214/7110683.patch,
		* patches/security/20120214/7110687.patch,
		* patches/security/20120214/7110700.patch,
		* patches/security/20120214/7110704.patch,
		* patches/security/20120214/7112642.patch,
		* patches/security/20120214/7118283.patch,
		* patches/security/20120214/7126960.patch: New security fixes.


changeset 76ed9cba5d9e in /hg/release/icedtea6-1.8
details: http://icedtea.classpath.org/hg/release/icedtea6-1.8?cmd=changeset;node=76ed9cba5d9e
author: Andrew John Hughes <ahughes at redhat.com>
date: Fri Feb 10 11:26:55 2012 +0000

	Prepare for 1.8.13 release.

	2012-02-10 Andrew John Hughes <ahughes at redhat.com>

	 * NEWS: Set release date for 1.8.13.
		* configure.ac: Bump to 1.8.13 proper.


changeset 30ca5e55eb8a in /hg/release/icedtea6-1.8
details: http://icedtea.classpath.org/hg/release/icedtea6-1.8?cmd=changeset;node=30ca5e55eb8a
author: Andrew John Hughes <ahughes at redhat.com>
date: Sat Feb 11 13:21:16 2012 +0000

	S7112642: Incorrect checking for graphics rendering object

	2012-02-10 Andrew John Hughes <ahughes at redhat.com>

	 * Makefile.am: Apply 7112642 security patch when
	XRender is enabled.
		* patches/security/20120214/7112642.patch: Additional security
	patch.


changeset a6cca6f7805a in /hg/release/icedtea6-1.8
details: http://icedtea.classpath.org/hg/release/icedtea6-1.8?cmd=changeset;node=a6cca6f7805a
author: Andrew John Hughes <ahughes at redhat.com>
date: Sat Feb 11 13:22:56 2012 +0000

	Merge


changeset 8c64a69895aa in /hg/release/icedtea6-1.8
details: http://icedtea.classpath.org/hg/release/icedtea6-1.8?cmd=changeset;node=8c64a69895aa
author: Andrew John Hughes <ahughes at redhat.com>
date: Mon Feb 13 11:59:15 2012 +0000

	Add CVE numbers.

	2012-02-13 Andrew John Hughes <ahughes at redhat.com>

	 * NEWS: Add CVE numbers.


changeset e58e239e2ccf in /hg/release/icedtea6-1.8
details: http://icedtea.classpath.org/hg/release/icedtea6-1.8?cmd=changeset;node=e58e239e2ccf
author: Andrew John Hughes <ahughes at redhat.com>
date: Mon Feb 13 11:59:25 2012 +0000

	Added tag icedtea6-1.8.13 for changeset 8c64a69895aa


diffstat:

 .hgtags                                 |    1 +
 ChangeLog                               |   46 ++
 Makefile.am                             |   13 +-
 NEWS                                    |   15 +-
 configure.ac                            |   29 +-
 jconsole.desktop                        |   10 -
 jconsole.desktop.in                     |   10 +
 patches/security/20120214/7082299.patch |  200 ++++++++++
 patches/security/20120214/7088367.patch |   43 ++
 patches/security/20120214/7110683.patch |  169 +++++++++
 patches/security/20120214/7110687.patch |  210 +++++++++++
 patches/security/20120214/7110700.patch |   34 +
 patches/security/20120214/7110704.patch |   39 ++
 patches/security/20120214/7112642.patch |  599 ++++++++++++++++++++++++++++++++
 patches/security/20120214/7118283.patch |   19 +
 patches/security/20120214/7126960.patch |   66 +++
 policytool.desktop                      |   10 -
 policytool.desktop.in                   |   10 +
 18 files changed, 1489 insertions(+), 34 deletions(-)

diffs (truncated from 1665 to 500 lines):

diff -r f096a6493463 -r e58e239e2ccf .hgtags
--- a/.hgtags	Thu Jan 12 13:04:39 2012 +0000
+++ b/.hgtags	Mon Feb 13 11:59:25 2012 +0000
@@ -33,3 +33,4 @@
 17524de1ad5c9871b0e2a96381630ef4d11ee737 icedtea6-1.8.10
 14bad91b28f287279c937f4e2c0e8665cdd9bdcf icedtea6-1.8.11
 70d67528801dbbb4fc8f841cc3ece3f65cf7ec9e icedtea6-1.8.12
+8c64a69895aaef7a53bd4ef5550d84e34a6a42ed icedtea6-1.8.13
diff -r f096a6493463 -r e58e239e2ccf ChangeLog
--- a/ChangeLog	Thu Jan 12 13:04:39 2012 +0000
+++ b/ChangeLog	Mon Feb 13 11:59:25 2012 +0000
@@ -1,3 +1,49 @@
+2012-02-13  Andrew John Hughes  <ahughes at redhat.com>
+
+	* NEWS: Add CVE numbers.
+
+2012-02-10  Andrew John Hughes  <ahughes at redhat.com>
+
+	* Makefile.am: Apply 7112642 security patch
+	when XRender is enabled.
+	* patches/security/20120214/7112642.patch:
+	Additional security patch.
+
+2012-01-25  Jiri Vanek  <jvanek at redhat.com>
+
+	fixes rhbz#580478
+	* configure.ac: abs-install-dir block moved outside conditional ENABLE_SYSTEMTAP block
+	 Added policytool.desktop and jconsole.desktop as AC_CONFIG_FILES
+	* jconsole.desktop:  removed, replaced by jconsole.desktop.in
+	* jconsole.desktop.in: new file, stub for desktop file, have variable
+	to be substituted during configure
+	* policytool.desktop:  removed, replaced by policytool.desktop.in
+	* policytool.desktop.in: new file, stub for desktop file, have variable
+	to be substituted during configure
+	* NEWS:  updated
+
+2012-02-10  Andrew John Hughes  <ahughes at redhat.com>
+
+	* NEWS: Set release date for 1.8.13.
+	* configure.ac: Bump to 1.8.13 proper.
+
+2012-02-08  Omair Majid  <omajid at redhat.com>
+
+	* NEWS: Update with security fixes.
+	* Makefile.am
+	(SECURITY_PATCHES): Add security patches.
+	(SPECIAL_SECURITY_PATCH): Add new variable.
+	(ICEDTEA_PATCHES): Add security patch that epends on backport.
+	* patches/security/20120214/7082299.patch,
+	* patches/security/20120214/7088367.patch,
+	* patches/security/20120214/7110683.patch,
+	* patches/security/20120214/7110687.patch,
+	* patches/security/20120214/7110700.patch,
+	* patches/security/20120214/7110704.patch,
+	* patches/security/20120214/7112642.patch,
+	* patches/security/20120214/7118283.patch,
+	* patches/security/20120214/7126960.patch: New security fixes.
+
 2012-01-12  Andrew John Hughes  <ahughes at redhat.com>
 
 	* NEWS: Add 1.8.13.
diff -r f096a6493463 -r e58e239e2ccf Makefile.am
--- a/Makefile.am	Thu Jan 12 13:04:39 2012 +0000
+++ b/Makefile.am	Mon Feb 13 11:59:25 2012 +0000
@@ -280,7 +280,17 @@
 	patches/security/20111018/7083012.patch \
 	patches/security/20111018/7096936.patch \
 	patches/security/20111018/7046794.patch \
-	patches/security/20111018/7077466.patch
+	patches/security/20111018/7077466.patch \
+	patches/security/20120214/7082299.patch \
+	patches/security/20120214/7088367.patch \
+	patches/security/20120214/7110683.patch \
+	patches/security/20120214/7110687.patch \
+	patches/security/20120214/7110700.patch \
+	patches/security/20120214/7110704.patch \
+	patches/security/20120214/7118283.patch \
+	patches/security/20120214/7126960.patch
+
+SPECIAL_SECURITY_PATCH = patches/security/20120214/7112642.patch
 
 ICEDTEA_PATCHES = \
 	$(SECURITY_PATCHES) \
@@ -466,6 +476,7 @@
 XRENDER_PATCHES = patches/xrender/icedtea-???.patch
 XRENDER_PATCH_FILES = $(sort $(wildcard $(abs_top_srcdir)/$(XRENDER_PATCHES)))
 ICEDTEA_PATCHES += $(sort $(subst $(abs_top_srcdir)/,,$(XRENDER_PATCH_FILES)))
+ICEDTEA_PATCHES += $(SPECIAL_SECURITY_PATCH)
 endif
 
 if ENABLE_NIO2
diff -r f096a6493463 -r e58e239e2ccf NEWS
--- a/NEWS	Thu Jan 12 13:04:39 2012 +0000
+++ b/NEWS	Mon Feb 13 11:59:25 2012 +0000
@@ -8,7 +8,20 @@
 
 CVE-XXXX-YYYY: http://www.cve.mitre.org/cgi-bin/cvename.cgi?name=XXXX-YYYY
 
-New in release 1.8.13 (XXXX-XX-XX):
+New in release 1.8.13 (2012-02-14):
+
+* Security fixes
+  - S7082299, CVE-2011-3571: Fix in AtomicReferenceArray
+  - S7088367, CVE-2011-3563: Fix issues in java sound
+  - S7110683, CVE-2012-0502: Issues with some KeyboardFocusManager method
+  - S7110687, CVE-2012-0503: Issues with TimeZone class
+  - S7110700, CVE-2012-0505: Enhance exception throwing mechanism in ObjectStreamClass
+  - S7110704, CVE-2012-0506: Issues with some method in corba
+  - S7112642, CVE-2012-0497: Incorrect checking for graphics rendering object
+  - S7118283, CVE-2012-0501: Better input parameter checking in zip file processing
+  - S7126960, CVE-2011-5035: Add property to limit number of request headers to the HTTP Server
+* Bug fixes
+  - RH580478: Desktop files should not use hardcoded path
 
 New in release 1.8.12 (2012-01-11):
 
diff -r f096a6493463 -r e58e239e2ccf configure.ac
--- a/configure.ac	Thu Jan 12 13:04:39 2012 +0000
+++ b/configure.ac	Mon Feb 13 11:59:25 2012 +0000
@@ -1,4 +1,4 @@
-AC_INIT([icedtea6],[1.8.13pre],[distro-pkg-dev at openjdk.java.net])
+AC_INIT([icedtea6],[1.8.13],[distro-pkg-dev at openjdk.java.net])
 AM_INIT_AUTOMAKE([1.9 tar-pax foreign])
 AC_CONFIG_FILES([Makefile])
 
@@ -192,6 +192,7 @@
   AC_CONFIG_FILES([javac], [chmod +x javac])
   AC_CONFIG_FILES([javap], [chmod +x javap])
 fi
+
 FIND_RHINO_JAR
 WITH_OPENJDK_SRC_ZIP
 WITH_HOTSPOT_SRC_ZIP
@@ -296,6 +297,21 @@
   fi
 fi
 
+AC_MSG_CHECKING([for absolute java home install dir])
+AC_ARG_WITH([abs-install-dir],
+	    [AS_HELP_STRING([--with-abs-install-dir], 
+			    [The absolute path where the j2sdk-image dir will be installed])],
+	    [if test "x${withval}" = x; then
+		ABS_JAVA_HOME_DIR="${abs_top_builddir}/${OPENJDK_BUILD_DIR}/j2sdk-image"
+	     else
+		ABS_JAVA_HOME_DIR="${withval}"
+	     fi], [ABS_JAVA_HOME_DIR="${abs_top_builddir}/${OPENJDK_BUILD_DIR}/j2sdk-image"])
+AC_MSG_RESULT([${ABS_JAVA_HOME_DIR}])
+AC_SUBST(ABS_JAVA_HOME_DIR)
+
+AC_CONFIG_FILES([jconsole.desktop])
+AC_CONFIG_FILES([policytool.desktop])
+
 if test "x${ENABLE_SYSTEMTAP}" = xyes; then
 AC_CHECK_HEADER([sys/sdt.h], [SDT_H_FOUND='yes'],
                 [SDT_H_FOUND='no';
@@ -337,19 +353,8 @@
 ]])], [AC_MSG_RESULT([yes])], [AC_MSG_ERROR([systemtap sdt.h or g++ too old])])
   AC_LANG_POP([C++])
 
-  AC_MSG_CHECKING([for absolute java home install dir])
-  AC_ARG_WITH([abs-install-dir],
-	      [AS_HELP_STRING([--with-abs-install-dir], 
-			      [The absolute path where the j2sdk-image dir will be installed])],
-	      [if test "x${withval}" = x; then
-		 ABS_JAVA_HOME_DIR="`pwd`/openjdk/build/${BUILD_OS_DIR}-${BUILD_ARCH_DIR}/j2sdk-image"
-	       else
-		 ABS_JAVA_HOME_DIR="${withval}"
-	       fi], [ABS_JAVA_HOME_DIR="`pwd`/openjdk/build/${BUILD_OS_DIR}-${BUILD_ARCH_DIR}/j2sdk-image"])
-  AC_MSG_RESULT([${ABS_JAVA_HOME_DIR}])
   ABS_CLIENT_LIBJVM_SO="${ABS_JAVA_HOME_DIR}/jre/lib/${INSTALL_ARCH_DIR}/client/libjvm.so"
   ABS_SERVER_LIBJVM_SO="${ABS_JAVA_HOME_DIR}/jre/lib/${INSTALL_ARCH_DIR}/server/libjvm.so"
-  AC_SUBST(ABS_JAVA_HOME_DIR)
   AC_SUBST(ABS_CLIENT_LIBJVM_SO)
   AC_SUBST(ABS_SERVER_LIBJVM_SO)
   AC_CONFIG_FILES([tapset/hotspot.stp])
diff -r f096a6493463 -r e58e239e2ccf jconsole.desktop
--- a/jconsole.desktop	Thu Jan 12 13:04:39 2012 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,10 +0,0 @@
-[Desktop Entry]
-Name=OpenJDK Monitoring & Management Console
-Comment=Monitor and manage OpenJDK applications
-Exec=/usr/bin/jconsole
-Icon=java
-Terminal=false
-Type=Application
-StartupWMClass=sun-tools-jconsole-JConsole
-Categories=Development;Monitor;Java;
-Version=1.0
diff -r f096a6493463 -r e58e239e2ccf jconsole.desktop.in
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/jconsole.desktop.in	Mon Feb 13 11:59:25 2012 +0000
@@ -0,0 +1,10 @@
+[Desktop Entry]
+Name=OpenJDK Monitoring & Management Console
+Comment=Monitor and manage OpenJDK applications
+Exec=@ABS_JAVA_HOME_DIR@/bin/jconsole
+Icon=java
+Terminal=false
+Type=Application
+StartupWMClass=sun-tools-jconsole-JConsole
+Categories=Development;Monitor;Java;
+Version=1.0
diff -r f096a6493463 -r e58e239e2ccf patches/security/20120214/7082299.patch
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/patches/security/20120214/7082299.patch	Mon Feb 13 11:59:25 2012 +0000
@@ -0,0 +1,201 @@
+# HG changeset patch
+# User robm
+# Date 1322691030 0
+# Node ID ee0f12b18cb8d20c3fb61e96817bde6318a29221
+# Parent  dd8956e41b892ed7102e1d5668781f2c68ea9ac5
+7082299: AtomicReferenceArray should ensure that array is Object[]
+Summary: java.util.concurrent.AtomicReferenceArray needs to ensure that internal array is always Object[].
+Reviewed-by: chegar, coffeys
+
+diff --git a/src/share/classes/java/util/concurrent/atomic/AtomicReferenceArray.java b/src/share/classes/java/util/concurrent/atomic/AtomicReferenceArray.java
+--- openjdk/jdk/src/share/classes/java/util/concurrent/atomic/AtomicReferenceArray.java
++++ openjdk/jdk/src/share/classes/java/util/concurrent/atomic/AtomicReferenceArray.java
+@@ -34,8 +34,9 @@
+  */
+ 
+ package java.util.concurrent.atomic;
++import java.lang.reflect.Array;
++import java.util.Arrays;
+ import sun.misc.Unsafe;
+-import java.util.*;
+ 
+ /**
+  * An array of object references in which elements may be updated
+@@ -49,15 +50,37 @@ public class AtomicReferenceArray<E> imp
+ public class AtomicReferenceArray<E> implements java.io.Serializable {
+     private static final long serialVersionUID = -6209656149925076980L;
+ 
+-    private static final Unsafe unsafe = Unsafe.getUnsafe();
+-    private static final int base = unsafe.arrayBaseOffset(Object[].class);
+-    private static final int scale = unsafe.arrayIndexScale(Object[].class);
+-    private final Object[] array;
++    private static final Unsafe unsafe;
++    private static final int base;
++    private static final int shift;
++    private static final long arrayFieldOffset;
++    private final Object[] array; // must have exact type Object[]
+ 
+-    private long rawIndex(int i) {
++    static {
++        int scale;
++        try {
++            unsafe = Unsafe.getUnsafe();
++            arrayFieldOffset = unsafe.objectFieldOffset
++                (AtomicReferenceArray.class.getDeclaredField("array"));
++            base = unsafe.arrayBaseOffset(Object[].class);
++            scale = unsafe.arrayIndexScale(Object[].class);
++        } catch (Exception e) {
++            throw new Error(e);
++        }
++        if ((scale & (scale - 1)) != 0)
++            throw new Error("data type scale not a power of two");
++        shift = 31 - Integer.numberOfLeadingZeros(scale);
++    }
++
++    private long checkedByteOffset(int i) {
+         if (i < 0 || i >= array.length)
+             throw new IndexOutOfBoundsException("index " + i);
+-        return base + (long) i * scale;
++
++        return byteOffset(i);
++    }
++
++    private static long byteOffset(int i) {
++        return ((long) i << shift) + base;
+     }
+ 
+     /**
+@@ -66,9 +89,6 @@ public class AtomicReferenceArray<E> imp
+      */
+     public AtomicReferenceArray(int length) {
+         array = new Object[length];
+-        // must perform at least one volatile write to conform to JMM
+-        if (length > 0)
+-            unsafe.putObjectVolatile(array, rawIndex(0), null);
+     }
+ 
+     /**
+@@ -79,18 +99,8 @@ public class AtomicReferenceArray<E> imp
+      * @throws NullPointerException if array is null
+      */
+     public AtomicReferenceArray(E[] array) {
+-        if (array == null)
+-            throw new NullPointerException();
+-        int length = array.length;
+-        this.array = new Object[length];
+-        if (length > 0) {
+-            int last = length-1;
+-            for (int i = 0; i < last; ++i)
+-                this.array[i] = array[i];
+-            // Do the last write as volatile
+-            E e = array[last];
+-            unsafe.putObjectVolatile(this.array, rawIndex(last), e);
+-        }
++        // Visibility guaranteed by final field guarantees
++        this.array = Arrays.copyOf(array, array.length, Object[].class);
+     }
+ 
+     /**
+@@ -109,7 +119,11 @@ public class AtomicReferenceArray<E> imp
+      * @return the current value
+      */
+     public final E get(int i) {
+-        return (E) unsafe.getObjectVolatile(array, rawIndex(i));
++        return getRaw(checkedByteOffset(i));
++    }
++
++    private E getRaw(long offset) {
++        return (E) unsafe.getObjectVolatile(array, offset);
+     }
+ 
+     /**
+@@ -119,7 +133,7 @@ public class AtomicReferenceArray<E> imp
+      * @param newValue the new value
+      */
+     public final void set(int i, E newValue) {
+-        unsafe.putObjectVolatile(array, rawIndex(i), newValue);
++        unsafe.putObjectVolatile(array, checkedByteOffset(i), newValue);
+     }
+ 
+     /**
+@@ -130,7 +144,7 @@ public class AtomicReferenceArray<E> imp
+      * @since 1.6
+      */
+     public final void lazySet(int i, E newValue) {
+-        unsafe.putOrderedObject(array, rawIndex(i), newValue);
++        unsafe.putOrderedObject(array, checkedByteOffset(i), newValue);
+     }
+ 
+ 
+@@ -143,9 +157,10 @@ public class AtomicReferenceArray<E> imp
+      * @return the previous value
+      */
+     public final E getAndSet(int i, E newValue) {
++        long offset = checkedByteOffset(i);
+         while (true) {
+-            E current = get(i);
+-            if (compareAndSet(i, current, newValue))
++            E current = getRaw(offset);
++            if (compareAndSetRaw(offset, current, newValue))
+                 return current;
+         }
+     }
+@@ -153,6 +168,7 @@ public class AtomicReferenceArray<E> imp
+     /**
+      * Atomically sets the element at position {@code i} to the given
+      * updated value if the current value {@code ==} the expected value.
++     *
+      * @param i the index
+      * @param expect the expected value
+      * @param update the new value
+@@ -160,8 +176,11 @@ public class AtomicReferenceArray<E> imp
+      * the actual value was not equal to the expected value.
+      */
+     public final boolean compareAndSet(int i, E expect, E update) {
+-        return unsafe.compareAndSwapObject(array, rawIndex(i),
+-                                         expect, update);
++        return compareAndSetRaw(checkedByteOffset(i), expect, update);
++    }
++
++    private boolean compareAndSetRaw(long offset, E expect, E update) {
++        return unsafe.compareAndSwapObject(array, offset, expect, update);
+     }
+ 
+     /**
+@@ -186,9 +205,33 @@ public class AtomicReferenceArray<E> imp
+      * @return the String representation of the current values of array.
+      */
+     public String toString() {
+-        if (array.length > 0) // force volatile read
+-            get(0);
+-        return Arrays.toString(array);
++        int iMax = array.length - 1;
++        if (iMax == -1)
++            return "[]";
++
++        StringBuilder b = new StringBuilder();
++        b.append('[');
++        for (int i = 0; ; i++) {
++            b.append(getRaw(byteOffset(i)));
++            if (i == iMax)
++                return b.append(']').toString();
++            b.append(',').append(' ');
++        }
++    }
++
++    /**
++     * Reconstitutes the instance from a stream (that is, deserializes it).
++     * @param s the stream
++     */
++    private void readObject(java.io.ObjectInputStream s)
++        throws java.io.IOException, ClassNotFoundException {
++        // Note: This must be changed if any additional fields are defined
++        Object a = s.readFields().get("array", null);
++        if (a == null || !a.getClass().isArray())
++            throw new java.io.InvalidObjectException("Not array type");
++        if (a.getClass() != Object[].class)
++            a = Arrays.copyOf((Object[])a, Array.getLength(a), Object[].class);
++        unsafe.putObjectVolatile(this, arrayFieldOffset, a);
+     }
+ 
+ }
diff -r f096a6493463 -r e58e239e2ccf patches/security/20120214/7088367.patch
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/patches/security/20120214/7088367.patch	Mon Feb 13 11:59:25 2012 +0000
@@ -0,0 +1,45 @@
+# HG changeset patch
+# User amenkov
+# Date 1319622989 -14400
+# Node ID b34a3ed0c8f2f6b9121d38ed330430d913f8a385
+# Parent  cdc68d7a17dd412402b100dc427abbe0a90cf2ab
+7088367: JavaSound security issue (12865443)
+Reviewed-by: denis
+
+diff --git a/src/share/classes/com/sun/media/sound/DirectAudioDevice.java b/src/share/classes/com/sun/media/sound/DirectAudioDevice.java
+--- openjdk/jdk/src/share/classes/com/sun/media/sound/DirectAudioDevice.java
++++ openjdk/jdk/src/share/classes/com/sun/media/sound/DirectAudioDevice.java
+@@ -771,7 +771,7 @@ class DirectAudioDevice extends Abstract
+             if (off < 0) {
+                 throw new ArrayIndexOutOfBoundsException(off);
+             }
+-            if (off + len > b.length) {
++            if ((long)off + (long)len > (long)b.length) {
+                 throw new ArrayIndexOutOfBoundsException(b.length);
+             }
+ 
+@@ -1000,7 +1000,7 @@ class DirectAudioDevice extends Abstract
+             if (off < 0) {
+                 throw new ArrayIndexOutOfBoundsException(off);
+             }
+-            if (off + len > b.length) {
++            if ((long)off + (long)len > (long)b.length) {
+                 throw new ArrayIndexOutOfBoundsException(b.length);
+             }
+             if (!isActive() && doIO) {
+diff --git a/src/share/classes/com/sun/media/sound/SoftMixingSourceDataLine.java b/src/share/classes/com/sun/media/sound/SoftMixingSourceDataLine.java
+--- openjdk/jdk/src/share/classes/com/sun/media/sound/SoftMixingSourceDataLine.java
++++ openjdk/jdk/src/share/classes/com/sun/media/sound/SoftMixingSourceDataLine.java
+@@ -130,6 +130,12 @@ public class SoftMixingSourceDataLine ex
+         if (len % framesize != 0)
+             throw new IllegalArgumentException(
+                     "Number of bytes does not represent an integral number of sample frames.");
++        if (off < 0) {
++            throw new ArrayIndexOutOfBoundsException(off);
++        }
++        if ((long)off + (long)len > (long)b.length) {
++            throw new ArrayIndexOutOfBoundsException(b.length);
++        }
+ 
+         byte[] buff = cycling_buffer;
+         int buff_len = cycling_buffer.length;
diff -r f096a6493463 -r e58e239e2ccf patches/security/20120214/7110683.patch
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/patches/security/20120214/7110683.patch	Mon Feb 13 11:59:25 2012 +0000
@@ -0,0 +1,170 @@
+# HG changeset patch
+# User skoppar
+# Date 1324575564 28800
+# Node ID e05eb7bee1ce0a44f3e414454e44cd49d77ba9de
+# Parent  bfaa99d5bef813217cdbc6eddcdd511cf53327e7
+7110683: Issues with some KeyboardFocusManager method
+7116384: backout the unallowed changes in the KeyboardFocusManager.java javadoc
+Reviewed-by: ant
+
+diff --git a/src/share/classes/java/awt/KeyboardFocusManager.java b/src/share/classes/java/awt/KeyboardFocusManager.java
+--- openjdk/jdk/src/share/classes/java/awt/KeyboardFocusManager.java
++++ openjdk/jdk/src/share/classes/java/awt/KeyboardFocusManager.java
+@@ -1,5 +1,5 @@
+ /*
+- * Copyright 2000-2007 Sun Microsystems, Inc.  All Rights Reserved.
++ * Copyright 2000-2011 Sun Microsystems, Inc.  All Rights Reserved.
+  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+  *
+  * This code is free software; you can redistribute it and/or modify it
+@@ -476,14 +476,8 @@ public abstract class KeyboardFocusManag
+      */
+     protected Component getGlobalFocusOwner() throws SecurityException {
+         synchronized (KeyboardFocusManager.class) {
+-            if (this == getCurrentKeyboardFocusManager()) {
+-                return focusOwner;
+-            } else {
+-                if (focusLog.isLoggable(Level.FINER)) {
+-                    focusLog.log(Level.FINER, "This manager is " + this + ", current is " + getCurrentKeyboardFocusManager());
+-                }
+-                throw new SecurityException(notPrivileged);
+-            }
++            checkCurrentKFMSecurity();
++            return focusOwner;
+         }
+     }
+ 
+@@ -517,6 +511,7 @@ public abstract class KeyboardFocusManag
+ 
+         if (focusOwner == null || focusOwner.isFocusable()) {



More information about the distro-pkg-dev mailing list