Your message dated Fri, 25 Apr 2025 13:29:50 +0200
with message-id <88b08182-df3f-499f-b588-b705afe45...@debian.org>
and subject line zip -X doesn't strip times
has caused the Debian Bug report #71032,
regarding zip -X doesn't strip times
to be marked as done.
This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.
(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact ow...@bugs.debian.org
immediately.)
--
71032: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=71032
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems
--- Begin Message ---
Package: zip
Version: 2.20-2
Hello,
when running zip -X, the file times are not stripped, contrary to
the man page. Also, running zip -A doesn't yield a file that is
identified as an MS-DOS executable afterwards. I think this is
what the program should do, and also what the man page suggests,
since it makes no sense to make room for a program and then not
including it. I had to resort to NT to create a self-extracting
archive, and it still had it's times in :(
Best Regards,
--Toni++
-- System Information
Debian Release: potato
Kernel Version: Linux oak 2.0.38 #6 Sat Dec 4 16:31:11 CET 1999 i686 unknown
Versions of the packages zip depends on:
ii libc6 2.1.3-13 GNU C Library: Shared libraries and Timezone
--- End Message ---
--- Begin Message ---
Hello.
I have finally an official reply from one of the authors (in Cc),
which I'll reproduce below.
Thanks.
Paul Marquess <paul.marqu...@outlook.com> writes:
---------------------------------------------------------------
I suspect there is confusion here about the optional extended date/time field
and the mandatory DOS date time that MUST be present in every zip file. It is
possible to exclude the extended attribute, but the DOS data time cannot be
excluded (it can be set to zero, but it has to be present).
The key point about the 2.3 documentation for -X is where it says "Do not save extra
file attributes". The standard date/time is not an extended attribute.
Just to double check this is what I get with a vanilla zip 2.32
Create two zip files, one with standard options, the other using the -X option.
$ zip /tmp/23.zip deflate.c
$ zip -X /tmp/23x.zip deflate.c
Looking inside the standard zip file, 23.zip you can see the presence of the
'UT: Extended Timestamp' field and the standard DOS date time field (Last Mod
Time 3275050F 'Mon Mar 21 00:40:30 2005').
$ zipdetails -v /tmp/23.zip
0000 0004 50 4B 03 04 LOCAL HEADER #1 04034B50
0004 0001 14 Extract Zip Spec 14 '2.0'
0005 0001 00 Extract OS 00 'MS-DOS'
0006 0002 00 00 General Purpose Flag 0000
[Bits 1-2] 0 'Normal Compression'
0008 0002 08 00 Compression Method 0008 'Deflated'
000A 0004 0F 05 75 32 Last Mod Time 3275050F 'Mon Mar 21 00:40:30 2005'
000E 0004 C1 3C 82 87 CRC 87823CC1
0012 0004 96 26 00 00 Compressed Length 00002696
0016 0004 E0 85 00 00 Uncompressed Length 000085E0
001A 0002 09 00 Filename Length 0009
001C 0002 1C 00 Extra Length 001C
001E 0009 64 65 66 6C Filename 'deflate.c'
61 74 65 2E
63
0027 0002 55 54 Extra ID #0001 5455 'UT: Extended Timestamp'
0029 0002 09 00 Length 0009
002B 0001 03 Flags '03 mod access'
002C 0004 FE 17 3E 42 Mod Time 423E17FE 'Mon Mar 21 00:40:30 2005'
0030 0004 FE 17 3E 42 Access Time 423E17FE 'Mon Mar 21 00:40:30 2005'
0034 0002 75 78 Extra ID #0002 7875 'ux: Unix Extra Type 3'
0036 0002 0B 00 Length 000B
0038 0001 01 Version 01
0039 0001 04 UID Size 04
003A 0004 EA 03 00 00 UID 000003EA
003E 0001 04 GID Size 04
003F 0004 EA 03 00 00 GID 000003EA
0043 2696 ... PAYLOAD
26D9 0004 50 4B 01 02 CENTRAL HEADER #1 02014B50
26DD 0001 1E Created Zip Spec 1E '3.0'
26DE 0001 03 Created OS 03 'Unix'
26DF 0001 14 Extract Zip Spec 14 '2.0'
26E0 0001 00 Extract OS 00 'MS-DOS'
26E1 0002 00 00 General Purpose Flag 0000
[Bits 1-2] 0 'Normal Compression'
26E3 0002 08 00 Compression Method 0008 'Deflated'
26E5 0004 0F 05 75 32 Last Mod Time 3275050F 'Mon Mar 21 00:40:30 2005'
26E9 0004 C1 3C 82 87 CRC 87823CC1
26ED 0004 96 26 00 00 Compressed Length 00002696
26F1 0004 E0 85 00 00 Uncompressed Length 000085E0
26F5 0002 09 00 Filename Length 0009
26F7 0002 18 00 Extra Length 0018
26F9 0002 00 00 Comment Length 0000
26FB 0002 00 00 Disk Start 0000
26FD 0002 01 00 Int File Attributes 0001
[Bit 0] 1 Text Data
26FF 0004 00 00 FF 81 Ext File Attributes 81FF0000
2703 0004 00 00 00 00 Local Header Offset 00000000
2707 0009 64 65 66 6C Filename 'deflate.c'
61 74 65 2E
63
2710 0002 55 54 Extra ID #0001 5455 'UT: Extended Timestamp'
2712 0002 05 00 Length 0005
2714 0001 03 Flags '03 mod access'
2715 0004 FE 17 3E 42 Mod Time 423E17FE 'Mon Mar 21 00:40:30 2005'
2719 0002 75 78 Extra ID #0002 7875 'ux: Unix Extra Type 3'
271B 0002 0B 00 Length 000B
271D 0001 01 Version 01
271E 0001 04 UID Size 04
271F 0004 EA 03 00 00 UID 000003EA
2723 0001 04 GID Size 04
2724 0004 EA 03 00 00 GID 000003EA
2728 0004 50 4B 05 06 END CENTRAL HEADER 06054B50
272C 0002 00 00 Number of this disk 0000
272E 0002 00 00 Central Dir Disk no 0000
2730 0002 01 00 Entries in this disk 0001
2732 0002 01 00 Total Entries 0001
2734 0004 4F 00 00 00 Size of Central Dir 0000004F
2738 0004 D9 26 00 00 Offset to Central Dir 000026D9
273C 0002 00 00 Comment Length 0000
Done
and now the zip file, 23x.zip created with the -X option. In this case there is
no 'UT: Extended Timestamp' field present. The -X option has done what it was
asked to do -- it excluded extended attributes.
$ zipdetails -v /tmp/23x.zip
0000 0004 50 4B 03 04 LOCAL HEADER #1 04034B50
0004 0001 14 Extract Zip Spec 14 '2.0'
0005 0001 00 Extract OS 00 'MS-DOS'
0006 0002 00 00 General Purpose Flag 0000
[Bits 1-2] 0 'Normal Compression'
0008 0002 08 00 Compression Method 0008 'Deflated'
000A 0004 0F 05 75 32 Last Mod Time 3275050F 'Mon Mar 21 00:40:30 2005'
000E 0004 C1 3C 82 87 CRC 87823CC1
0012 0004 96 26 00 00 Compressed Length 00002696
0016 0004 E0 85 00 00 Uncompressed Length 000085E0
001A 0002 09 00 Filename Length 0009
001C 0002 00 00 Extra Length 0000
001E 0009 64 65 66 6C Filename 'deflate.c'
61 74 65 2E
63
0027 2696 ... PAYLOAD
26BD 0004 50 4B 01 02 CENTRAL HEADER #1 02014B50
26C1 0001 1E Created Zip Spec 1E '3.0'
26C2 0001 03 Created OS 03 'Unix'
26C3 0001 14 Extract Zip Spec 14 '2.0'
26C4 0001 00 Extract OS 00 'MS-DOS'
26C5 0002 00 00 General Purpose Flag 0000
[Bits 1-2] 0 'Normal Compression'
26C7 0002 08 00 Compression Method 0008 'Deflated'
26C9 0004 0F 05 75 32 Last Mod Time 3275050F 'Mon Mar 21 00:40:30 2005'
26CD 0004 C1 3C 82 87 CRC 87823CC1
26D1 0004 96 26 00 00 Compressed Length 00002696
26D5 0004 E0 85 00 00 Uncompressed Length 000085E0
26D9 0002 09 00 Filename Length 0009
26DB 0002 00 00 Extra Length 0000
26DD 0002 00 00 Comment Length 0000
26DF 0002 00 00 Disk Start 0000
26E1 0002 01 00 Int File Attributes 0001
[Bit 0] 1 Text Data
26E3 0004 00 00 FF 81 Ext File Attributes 81FF0000
26E7 0004 00 00 00 00 Local Header Offset 00000000
26EB 0009 64 65 66 6C Filename 'deflate.c'
61 74 65 2E
63
26F4 0004 50 4B 05 06 END CENTRAL HEADER 06054B50
26F8 0002 00 00 Number of this disk 0000
26FA 0002 00 00 Central Dir Disk no 0000
26FC 0002 01 00 Entries in this disk 0001
26FE 0002 01 00 Total Entries 0001
2700 0004 37 00 00 00 Size of Central Dir 00000037
2704 0004 BD 26 00 00 Offset to Central Dir 000026BD
2708 0002 00 00 Comment Length 0000
Done
--- End Message ---