-
-
Notifications
You must be signed in to change notification settings - Fork 271
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Timestamps of zipped files are UTC #244
Comments
Code for above: `
` |
Hi, Thanks for reporting this with a detailed example. The ZIP format has very limited support for preserving date and time information of files. It doesn't offer a field to store time zone information so the archiving library can only assume that the stored timestamps are in the local time zone (or store that information elsewhere - e.g. in a separate file within the archive). (https://en.wikipedia.org/wiki/ZIP_(file_format)#Structure). |
It looks like this has been addressed for other archivers? |
Implementing the "Extended Timestamp Extra Field" would work for me. If you can provide a PR, I can review it and try to get it into an upcoming release. |
Summary
I zip a file from the iOS filesystem (log file). I then read that file as data and send it as an attachment in an email. When I receive the email, the zip file itself has the correct timestamp, but when I extract the zip, the enclosed file has a timestamp that equates to UTC (i.e. tomorrow for me, US Mountain time)
Steps to Reproduce
Create a file in iOS
Zip the file
Send the file
Extract the file
Observe the modification time of the file.
Expected Results
The timestamp of the extracted file should be in your timezone if originator and recipient are in the same timezone
Actual Results
The timezone is "tomorrow", 7 hours ahead, which is my UTC offset.
Regression & Version
Related Link
The text was updated successfully, but these errors were encountered: