I want my script to automatically encrypt my files.
Linux - SecurityThis forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I want my script to automatically encrypt my files.
Hi there
I would like my backup script to automatically encrypt my files that are sent to an external host via scp.
So in the script, just before scp is called, i would like to pass an encryption command..
I know a couple encryption tools, like gpg and bcrypt, but they require a user input for the passphrase...
Also note that if you pass a password to openssl on the command line like that, anyone who runs 'ps' on the system while openssl is running will see the password!
"worthless" is a bit extreme. SSL, GPG, IPSec, SSH etc all use encryption keys read from disk, and they are hardly "worthless".
Sure, but that's a different context. In this context (which is the same as people wanting to use LUKS or run an obfuscated binary combined with automagically providing the passphrase) it almost always is. It's not the encryption method that's the problem here, but the way it's misused. I mean, if this practice would have been secure (channel, sender or message integrity) AND convenient it would already have been provided for, wouldn't it?..
Quote:
Originally Posted by grepmasterd
The right approach is to just be careful about when keys might be exposed and mitigate against those cases.
I agree, though depending on what the recipient expects the integrity/security to be I wonder the user knows what is then expected from him...
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.