JDK-6561380 : JRE 6 overtakes OpenOffice.org 2 OpenDocument Format file association
  • Type: Bug
  • Component: install
  • Sub-Component: install
  • Affected Version: 6
  • Priority: P5
  • Status: Closed
  • Resolution: Duplicate
  • OS: linux
  • CPU: x86
  • Submitted: 2007-05-23
  • Updated: 2010-04-04
  • Resolved: 2007-05-29
Related Reports
Duplicate :  
Description
FULL PRODUCT VERSION :
jre-1.6.0_01-fcs

ADDITIONAL OS VERSION INFORMATION :
First noticed on Fedora Core 5 but verified on "FC7 test 4."

Linux localhost.localdomain 2.6.21-1.3142.fc7 #1 SMP Mon May 7 21:14:09 EDT 2007 i686 i686 i386 GNU/Linux


EXTRA RELEVANT SYSTEM CONFIGURATION :
FC7 is Gnome 2.18 and FC6 is (IIRC) Gnome 2.14(?).

A DESCRIPTION OF THE PROBLEM :
All ODF icons become Java icons.  When opening, Nautilus works about a security problem.

STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
  To reproduce:
1. Install OpenOffice.org 2.2.0 from http://download.openoffice.org
2. Install JRE jre-1.6.0_01-fcs RPM from http://java.com
3. Open a ODF in Nautilus


EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
Document opens in OOo.
ACTUAL -
Nautilus warning

ERROR MESSAGES/STACK TRACES THAT OCCUR :
Cannot open test.odt
The filename "test.odt" indicates that this file is of type "OpenDocument Text". The contents of the file indicate that the file is of type "Java Archive". If you open this file, the file might present a security risk to your system.

Do not open the file unless you created the file yourself, or received the file from a trusted source. To open the file, rename the file to the correct extension for "Java Archive", then open the file normally. Alternatively, use the Open With menu to choose a specific application for the file.

REPRODUCIBILITY :
This bug can be reproduced always.

CUSTOMER SUBMITTED WORKAROUND :
Right click to choose OOo

Comments
WORK AROUND Fix in file /usr/share/mime/packages/x-java-archive.xml <glob pattern="*.jar"/> <magic priority="85"> <match type="string" value="PK\003\004" offset="0"> - match type="host16" value="0xcafe" offset="40" /> + <match type="host16" value="0xcafe" offset="40" /> </match> </magic> </mime-type>
29-05-2007

EVALUATION 6u1 installation creates /usr/share/mime/packages/x-java-archive.xml. In this file, the second "match" tag misses the leading "<". This causes Nautilus to identify all Zip Archives as Java Archives. One effect is that OpenOffice documents can no longer be opened, because Nautilus complains about a mismatch between filename extension and file contents. This is the same bug as 6510610 which is fixed in 6U2 & 7. -rajani kaja
29-05-2007