Stephan van Hulst wrote:There's a lot you're not telling us.
Is this a web application? Will the code run on a server? What kind of string needs to be encrypted? Why does it need to be decrypted? How long will the string be stored/used? How often will it be retrieved/decrypted? Who's key will be used to encrypt the string?
Security is never "automatic". It depends on a lot of variables that you have to think hard on.
I want to create an encrypted 7z archive daily using 7-Zip software (i.e. using subprocess.run()), so:
- The sensitive string holds the password
- The string should be decrypted and passed as an argument to 7z exectutable, something like this:
- The code won't run on a server and won't be used in a web app
- It will be retrieved twice daily, once for creating the archive and once for
testing its integrity
- It should remain stored for as long as possible, at least 30 days
Regarding the
word "automatic", I just meant that everything is done without user involvement while still being secure