Open password protected ZIP in Android?

前端 未结 3 2100
暖寄归人
暖寄归人 2021-01-16 04:46

is there an library or a simple way how to open a password protected ZIP archive in Android? I know there are different types of ZIP encryption. I would like to open the mos

相关标签:
3条回答
  • 2021-01-16 04:58

    I found a .jar library that works on Android and can decompress and decrypt ZIP 2.0 files. http://www.lingala.net/zip4j/download.php

    It worked for me (encrypted ZIP created in Ubuntu and decrypted in Android).

    There might be a way to get it done without any library as described here: Implementation of ZipCrypto / Zip 2.0 encryption in java, but I was not able to get this code to work.

    0 讨论(0)
  • 2021-01-16 05:00

    You can also take a look at this library that can zip and unzip files with password easily:

    Unzip:

    ZipArchive zipArchive = new ZipArchive();
    zipArchive.unzip(targetPath,destinationPath,password);
    

    The documentation of this library is good enough, I just added a few examples from there. It's totally free and wrote specially for android.

    0 讨论(0)
  • 2021-01-16 05:22

    Check out http://code.google.com/p/winzipaes/

    And there are several questions here tagged in Java dealing with Zip encryption you might look at.

    0 讨论(0)
提交回复
热议问题