[Cryptography-dev] How to encrypt-decrypt a file?

2016-11-13 Thread Virgil Stokes
I have looked at all the documentation and postings that I could find on cryptography and still have been unable to find how to use it with file(s). Anyone's help on this would be greatly appreciated. --V ___ Cryptography-dev mailing list Cryptograph

Re: [Cryptography-dev] How to encrypt-decrypt a file?

2016-11-13 Thread Paul Kehrer
Hi Virgil, If you're dealing with a small file (where small is defined as "amount you're willing to buffer in memory") then you can just read the file, encrypt it using Fernet, and then write the results to disk. If the file is bigger then you'll want to read the file in chunks, pass those chunks