Encrypt the file for security

298 views Asked by At

Actually I have a file . I am working in linux environment. I need to encrypt that file for secure purpose with giving the some password. The operation could be like zip , tar any compression. When I extract the file It should ask me password , only then it should get extracted

Thanks in Advance

5

There are 5 answers

0
legoscia On BEST ANSWER

gpg --symmetric and gpg --decrypt should do what you want.

2
MJB On

Did you try vi -x filename ? It is not exactly full-featured encryption, but it might do what you want.

0
John Gietzen On

I would use GPG.

Or, you can use any zip library that supports AES...

0
Shyam On

Simple, use openssl.

openssl enc -aes-256-cbc -salt -in plain.txt -out myultrasecretfile.enc

If you want to compress before, that is your choice.

0
Marcin On

i like aespipe as you can use it completely non-interactively from command line or scripts, and it will work with any stream of data.