3

The iWork 2013 file format includes .iwa (iWork Archive) files stored within a .zip file. "IWA files are stored in Snappy's framing format, though they do not adhere rigorously to the spec. In particular, they do not include the required Stream Identifier chunk, and compressed chunks do not include a CRC-32C checksum." https://github.com/obriensp/iWorkFileFormat/blob/master/Docs/index.md#iwa

Is there an implementation of Snappy that can decompress files missing these components? If so, is there example code?

Examples of iWork files may be found at the bottom of this page: http://fileformats.archiveteam.org/wiki/IWA. For instance, unzipping file TestReport.pages.zip shows that it contains Index.zip, which contains .iwa files.

I tried decompressing the .iwa files using the Snappy for Windows command line tool here: http://snappy.angeloflogic.com/downloads/ . However, I received the error: "Found invalid data while decoding."

I do not yet have sample code because I do not know which implementation of Snappy I should base my code on.

Jacob Quisenberry
  • 1,131
  • 3
  • 20
  • 48
  • Wow, exciting. Unless you find an iWork-specific decompressor, I think you need to take an existing library that works with the Snappy framing format and modify it. What language are you working with? – twotwotwo Dec 13 '14 at 00:49
  • @twotwotwo, I prefer C#, followed by Java, but I am open to others. – Jacob Quisenberry Dec 13 '14 at 00:52
  • 1
    Got it. I only know Go options; https://github.com/mreiferson/go-snappystream looks good. https://github.com/twotwotwo/sz/ is mine but it's hard to recommend it because I haven't written a test suite. There are links there to the format spec and so on, which you might explore to get closer to what you want. – twotwotwo Dec 13 '14 at 01:02
  • If the file is < 64k try to remove the 4 first byte of your iwa and you should get the protobuffer stream. – v1nce May 13 '21 at 21:37

0 Answers0