7-zip 9.20 fails to extract zip produced by yazl
joaomoreno opened this issue · 5 comments
My script creates the simplest zip file possible:
var yazl = require('yazl');
var fs = require('fs');
var zipfile = new yazl.ZipFile();
var ostream = fs.createWriteStream('out.zip');
zipfile.outputStream.pipe(ostream);
zipfile.addBuffer(new Buffer('hello'), 'hello.txt');
zipfile.end();
I cannot extract this file with 7-zip 9.20 (its latest stable release). This application has a feature that verifies an archive and with the produced zip I get:
I can successfully extract it using the native Windows Extract...
context menu action. I can also extract it using 7-zip 9.38 (their latest beta release).
I've reproduced this issue. It is difficult to be motivated to do anything in response to this, knowing that the next version of 7-zip fixes what appears to be their incompatibility with the zip file spec.
I'll play around with the old (stable) version of 7-zip to see if there's something easy to be done about it.
Thanks, I'd be awesome to nail it, since many users are still on 9.20 and there's no automatic update feature in that app. 👍
I've determined that 7-zip 9.20 does not support general purpose bit 3. see https://github.com/thejoshwolfe/yazl/blob/master/README.md#general-purpose-bit-flag for why yazl relies on general purpose bit 3 being supported. See also #13 (opened in response to this issue).
here was my test to determine that 7-zip 9.20 does not support general purpose bit 3:
http://wolfesoftware.com/zip_without_general_purpose_bit_3.zip
version 2.2.0 is published. see the note here for how to create zip files with yazl that 7-Zip 9.20 can read: https://github.com/thejoshwolfe/yazl/blob/master/README.md#addbufferbuffer-metadatapath-options