Skip to main content

Encryption for zipfile

Project description

zipencrypt is a Python module to provide weak password-based encryption for zipfiles. It is meant as a drop-in replacement for zipfile from the standard lib and provides the counterpart to the decryption implemented there.

It is implemented in pure python and does not rely on any 3rd party libraries.

Compatible to python 2.7 and 3.4+

Installation

pip install zipencrypt

The code

from zipencrypt import ZipFile

with ZipFile("file.zip", mode="w") as f:
    f.writestr("file1.txt", "plaintext", pwd=b"password")

Do not use this!

The standard encryption of ZIP is known to be seriously flawed (see here). That is probably the reason why it is not implemented in zipfile in the standard lib. There are however legitimate use cases.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for zipencrypt, version 0.3.1
Filename, size File type Python version Upload date Hashes
Filename, size zipencrypt-0.3.1.tar.gz (21.8 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page