You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on May 22, 2021. It is now read-only.
When you upload multiple files together uncompressed/unarchived, apparently files are archived as UTF-8 encoded Send-Archive.zip without setting Language encoding flag (EFS). cf. https://pkware.cachefly.net/webdocs/casestudies/APPNOTE.TXT
As a result these zip files show garbled filenames in contents on Windows.
You can reproduce this problem by uploading 2 files such as "サンプル1-sample1" and "サンプル2-sample2", or whatever containing non-ASCII characters from Windows and downloading it on Windows.
Although I have not tested, maybe it can be fixed by changing v.setUint16(6, 8, true); // bit flags (8 = use data descriptor)
to v.setUint16(6, 2056, true); // bit flags (2056 = use data descriptor(8) + utf8-encoded(2048))
in https://github.com/mozilla/send/blob/master/app/zip.js#L32
The text was updated successfully, but these errors were encountered:
@Napier-JP You probably need to also update the same EFS bit in the same field in the directory entry records too since that is where the filenames actually reside. The zip archive format has a number of duplicated fields and the general purpose bit flags is just one of those.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
When you upload multiple files together uncompressed/unarchived, apparently files are archived as UTF-8 encoded Send-Archive.zip without setting Language encoding flag (EFS). cf. https://pkware.cachefly.net/webdocs/casestudies/APPNOTE.TXT
As a result these zip files show garbled filenames in contents on Windows.
You can reproduce this problem by uploading 2 files such as "サンプル1-sample1" and "サンプル2-sample2", or whatever containing non-ASCII characters from Windows and downloading it on Windows.
Although I have not tested, maybe it can be fixed by changing
v.setUint16(6, 8, true); // bit flags (8 = use data descriptor)
to
v.setUint16(6, 2056, true); // bit flags (2056 = use data descriptor(8) + utf8-encoded(2048))
in https://github.com/mozilla/send/blob/master/app/zip.js#L32
The text was updated successfully, but these errors were encountered: