Bug 1130693 - file-libs magic is broken for msooxml
Summary: file-libs magic is broken for msooxml
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: file
Version: 20
Hardware: x86_64
OS: Linux
unspecified
unspecified
Target Milestone: ---
Assignee: Jan Kaluža
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-08-16 10:00 UTC by Arcadiy Ivanov
Modified: 2014-09-23 04:33 UTC (History)
2 users (show)

Fixed In Version: file-5.19-6.fc21
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-09-09 22:10:15 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
Original magic, modified magic and test zip archive (411.84 KB, application/gzip)
2014-08-16 10:00 UTC, Arcadiy Ivanov
no flags Details

Description Arcadiy Ivanov 2014-08-16 10:00:12 UTC
Created attachment 927325 [details]
Original magic, modified magic and test zip archive

Description of problem:

Due to magic definition for MS OOXML every zip archive I've encountered is detected as MS OOXML. This breaks mc's virtual fs and view functions and who knows what else.

Version-Release number of selected component (if applicable):

file-libs-5.19-1.fc20.x86_64

How reproducible:

Attached is a tar containing three files:

hal-console-2.2.6.Final-overlay.zip - test archive that is not OOXML
magic - modified magic with OOXML detection commented out
magic.bak - original magic from file-libs-5.19-1

Steps to reproduce: 

Untar TGZ and cd into the directory. Follow examples below.

Actual results:

# file -m magic.bak hal-console-2.2.6.Final-overlay.zip 
hal-console-2.2.6.Final-overlay.zip: Microsoft OOXML
# file -m magic hal-console-2.2.6.Final-overlay.zip 
hal-console-2.2.6.Final-overlay.zip: Zip archive data, at least v1.0 to extract

Expected results:

# file -m magic.bak hal-console-2.2.6.Final-overlay.zip 
hal-console-2.2.6.Final-overlay.zip: Zip archive data, at least v1.0 to extract
# file -m magic hal-console-2.2.6.Final-overlay.zip 
hal-console-2.2.6.Final-overlay.zip: Zip archive data, at least v1.0 to extract

Additional info:

None

Comment 1 Jan Kaluža 2014-09-03 07:09:43 UTC
This is fixed in upstream commit https://github.com/file/file/commit/bf3fea9e6c0b18e9a645d2a796a1e3ae29be5ee5

Comment 2 Fedora Update System 2014-09-03 11:00:35 UTC
file-5.19-6.fc21 has been submitted as an update for Fedora 21.
https://admin.fedoraproject.org/updates/file-5.19-6.fc21

Comment 3 Fedora Update System 2014-09-03 11:12:26 UTC
file-5.19-6.fc20 has been submitted as an update for Fedora 20.
https://admin.fedoraproject.org/updates/file-5.19-6.fc20

Comment 4 lnie 2014-09-04 03:16:07 UTC
Tested with file-5.19-6.fc20 ,it seems that the bug is still there

Comment 5 Jan Kaluža 2014-09-04 06:09:47 UTC
How did you test it? You should *not* use File as described in Comment 0 with the "magic" and "magic.bak" files from test archive. Instead, just use:

file hal-console-2.2.6.Final-overlay.zip

Comment 6 lnie 2014-09-04 07:04:27 UTC
(In reply to Jan Kaluža from comment #5)
> How did you test it? You should *not* use File as described in Comment 0
> with the "magic" and "magic.bak" files from test archive. Instead, just use:
> 
> file hal-console-2.2.6.Final-overlay.zip

Just followed the reproduce steps in com0,and I got exactly the same results.
The output is :
file hal-console-2.2.6.Final-overlay.zip:
hal-console-2.2.6.Final-overlay.zip: Zip archive data, at least v1.0 to extract

Comment 7 Jan Kaluža 2014-09-04 07:23:59 UTC
This looks OK. In the old version, it shows "Microsoft OOXML", in the new version it shows "Zip archive data, at least v1.0 to extract", so the bug seems to be fixed.

Comment 8 Fedora Update System 2014-09-06 01:02:36 UTC
Package file-5.19-6.fc21:
* should fix your issue,
* was pushed to the Fedora 21 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing file-5.19-6.fc21'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2014-10254/file-5.19-6.fc21
then log in and leave karma (feedback).

Comment 9 Fedora Update System 2014-09-09 22:10:15 UTC
file-5.19-6.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 10 Fedora Update System 2014-09-23 04:33:28 UTC
file-5.19-6.fc21 has been pushed to the Fedora 21 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.