I have an encrypted ODT (Open Document Text) file and I need to unzip it. ODT is a ZIP file. Encrypted ODT is a regular ZIP file, only some files inside ZIP are encrypted.
Using ZipFile works well in the test, but I can not use ZipFile, because I have a stream in memory, I do not want to work with the file.
Therefore, I use ZipInputStream . But using ZipInputStream.getNextEntry () causes terrible only DEFLATED elements can have an EXT descriptor exception.
From what I can understand, it throws the first encrypted file inside the ZIP package, for example, in content.xml. Since OpenOffice encrypted the XML file, it was probably not compressed, and it was saved in a ZIP package without compression.
But ZipInputStream has a problem with this, and I don't see the way.
And yes, the encrypted ODT file was created by OpenOffice Writer 3.2.1. And yes, the stock ZipInputStream cannot even list through entries in it.
What can you offer?
source share