Visit our newest sister site!
Hundreds of free aircraft flight manuals
Civilian • Historical • Military • Declassified • FREE!

TUCoPS :: Web :: Apps :: va1990.htm

Sun Java JRE Pack200 Decompression Integer Overflow Vulnerability
iDefense Security Advisory 12.04.08: Sun Java JRE Pack200 Decompression Integer Overflow Vulnerability
iDefense Security Advisory 12.04.08: Sun Java JRE Pack200 Decompression Integer Overflow Vulnerability

Hash: SHA1

iDefense Security Advisory 12.02.08 
Dec 02, 2008


Pack200 is a compression method introduced by Sun in the 1.5 release of
the JRE. It is used to compress Jar files, and is optimized for the
compression of Java class files. A Java applet can be compressed using
the pack200 tool, and if the browser plugin supports the pack200-gzip
encoding it will pass the compressed Jar file to the JRE for unpacking.
For more information, see the vendor's site at the following links. 


Remote exploitation of an integer overflow vulnerability in Sun
Microsystems Inc.'s Java JRE could allow an attacker to execute
arbitrary code with the privileges of the current user.

The vulnerability occurs when reading the Pack200 compressed Jar file
during decompression. In order to calculate the size of a heap buffer,
the code multiplies and adds several integers. The bounds of these
values are not checked, and the arithmetic operations can overflow.
This results in an undersized buffer being allocated, which leads to a
heap based buffer overflow.


Exploitation allows attackers to execute arbitrary code in the context
of the currently logged-on user. To exploit this vulnerability, a
targeted user must load a malicious Web page created by an attacker. An
attacker typically accomplishes this via social engineering or injecting
content into compromised, trusted sites.

Exploitation of heap overflow vulnerabilities on modern operating
systems can at times be difficult due to various heap integrity
protections. However, the Pack200 code uses a custom allocator that
does not contain such integrity checks. Labs testing has demonstrated
that code execution is possible on the Linux platform. A similar
methodology is likely to be successful on the Windows platform.


iDefense has confirmed the existence of this vulnerability in Sun
Microsystem Inc.'s Java JRE version 1.6.0_07 for Windows and Linux.
According to Sun, Pack200 was first introduced in JRE 1.5.0. The latest
version of JRE 1.5, 1.5.0_15, does contain the vulnerable code, but the
browser plugin does not handle Pack200 encoding. As such, exploitation
through the browser does not appear to be possible with JRE 1.5.


The library containing the vulnerability can be renamed, which will
prevent it from being loaded. This workaround will prevent users from
loading Pack200 format Jar files, and from using the pack/unpack tools
that come with the JRE. However, normal applets and Java applications
will continue to function correctly. The vulnerable library is called
'unpack', and can be found in:

"%SYSTEMDRIVE%\Program Files\Java\JAVA VERSION\bin\unpack.dll"

on Windows, and in differing locations dependent upon the
distribution/platform on Unix systems.


Sun Microsystem Inc.'s has released a patch which addresses this issue.
For more information, consult their advisory at the following URL. 


A Mitre Corp. Common Vulnerabilities and Exposures (CVE) number has not
been assigned yet.


10/02/2008  Initial Vendor Notification
11/25/2008  Initial Vendor Reply
12/02/2008  Coordinated Public Disclosure


This vulnerability was reported to iDefense by regenrecht.

Get paid for vulnerability research 

Free tools, research and upcoming events 


Copyright =A9 2008 iDefense, Inc.

Permission is granted for the redistribution of this alert
electronically. It may not be edited in any way without the express
written consent of iDefense. If you wish to reprint the whole or any
part of this alert in any other medium other than electronically,
please e-mail for permission. 

Disclaimer: The information in the advisory is believed to be accurate
at the time of publishing based on currently available information. Use
of the information constitutes acceptance for use in an AS IS condition.
~ There are no warranties with regard to this information. Neither the
author nor the publisher accepts any liability for any direct,
indirect, or consequential loss or damage arising from use of, or
reliance on, this information.
Version: GnuPG v1.4.7 (MingW32)
Comment: Using GnuPG with Mozilla - 


TUCoPS is optimized to look best in Firefox® on a widescreen monitor (1440x900 or better).
Site design & layout copyright © 1986-2015 AOH