Bug 1139053

Summary: The -X option to unzip has never worked on Unix/Linux.
Product: [Fedora] Fedora Reporter: Joe Smith <joeinwap>
Component: unzipAssignee: Petr Stodulka <pstodulk>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 20CC: mluscon, pstodulk
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Windows   
Whiteboard:
Fixed In Version: unzip-6.0-17.fc21 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-12-07 04:40:04 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Patch to process.c (the -X option has never worked on Unix/Linux). none

Description Joe Smith 2014-09-07 21:01:17 UTC
Created attachment 935202 [details]
Patch to process.c (the -X option has never worked on Unix/Linux).

Description of problem: Files extracted with unzip are owned by root:root even when -X is specified.

Version-Release number of selected component: unzip-6.00.12fc20

How reproducible: Attempt to use -X, then use 'ls -l' on extracted files.

Steps to Reproduce:
1. Create a zip file archiving one or more files not owned by root:root.
   (Zip version 3.0) linux# zip /tmp/test.zip /home/*/.cshrc
2. mkdir /tmp/testing; cd /tmp/testing; unzip -X /tmp/test.zip
3. ls -l home/*/*

Actual results:
  All extracted files are owned by root:root.

Expected results:
  Extracted files should have correct owner and group IDs.

Additional info:
   The code for -X depends on preprocessor definitions that are never defined.
   This bug has been patched in Debian, but not RHEL or Fedora.

See comment #5 in 'Does "unzip -X" work in Info-ZIP UnZip 6.00?'
http://www.linuxquestions.org/questions/linux-software-2/does-unzip-x-work-in-info-zip-unzip-6-00-a-4175476765/#post5026340

Comment 1 Petr Stodulka 2014-11-21 15:38:36 UTC
Thanks for patch Joe. -X option works right now. Update will be done soon.

Comment 2 Fedora Update System 2014-11-27 15:50:19 UTC
unzip-6.0-17.fc21 has been submitted as an update for Fedora 21.
https://admin.fedoraproject.org/updates/unzip-6.0-17.fc21

Comment 3 Fedora Update System 2014-11-27 15:50:31 UTC
unzip-6.0-14.fc20 has been submitted as an update for Fedora 20.
https://admin.fedoraproject.org/updates/unzip-6.0-14.fc20

Comment 4 Fedora Update System 2014-11-27 15:51:44 UTC
unzip-6.0-13.fc19 has been submitted as an update for Fedora 19.
https://admin.fedoraproject.org/updates/unzip-6.0-13.fc19

Comment 5 Fedora Update System 2014-11-27 19:28:18 UTC
Package unzip-6.0-17.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 unzip-6.0-17.fc21'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2014-15892/unzip-6.0-17.fc21
then log in and leave karma (feedback).

Comment 6 Fedora Update System 2014-12-07 04:40:04 UTC
unzip-6.0-14.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 7 Fedora Update System 2014-12-17 04:41:15 UTC
unzip-6.0-17.fc21 has been pushed to the Fedora 21 stable repository.  If problems still persist, please make note of it in this bug report.