kushaldas / johnnycanencrypt

Python module for OpenPGP written in Rust.
GNU Lesser General Public License v3.0
51 stars 9 forks source link

Encrypt + decrypt a given filehandler object #51

Closed kushaldas closed 3 years ago

kushaldas commented 3 years ago

We should be able to pass a opened file handler to the encryption or decryption function.

For example:

with open(filepath, "rb") as fobj:
    ks.encrypt_filehandler_to_file(keys, fobj, outputpath, armor=True)

This should handle any object with a read method inside.