new to Python, been using it for a few months. One of my morning tasks is to encrypt a set of files and upload them to an FTP. It’s a very tedious task I was hoping to automate. The current keys came from the program PGP Desktop and have created public/private keys to encrypt files and eventually upload to an FTP. The same keys are used every day. Is there a way to encrypt a file using the already existing key(s) on my machine (as I know where they’re kept) to encrypt a file using python. The only articles I’ve found on SO involve creating a new key using python. Just wanting to bypass the morning ritual of right click > ‘Secure file with key…’. Currently we use no signing key, so it’s just the key for encrypting I need to use.
Asked
Active
Viewed 77 times
0
-
I would take a look at [this answer](http://stackoverflow.com/a/1053752/1433712). He is basically saying to use the subprocess module to run a command line utility that will encrypt the file for you. – Alden Apr 13 '17 at 20:56
-
The answer to your only question in there is "yes". – Maarten Bodewes Apr 14 '17 at 07:10
-
Alden, I read through it. It sounds like there's a lot of modifying modules in there, not something I'm too familiar with. He also cites what he uses may not be Windows stable (which I'm on). But I'll have to research more on it. Maarten,....can you cite an example? – AdagioYours Apr 14 '17 at 13:20
-
Bump - anyone ? – AdagioYours Apr 21 '17 at 16:22