HowTo: Keep Secrets in Linux Using CCRYPT

Easy. Who among you have a nasty dirty little secret? Ok. Let me just ask that another way: Who among you, keep all their passwords on a spreadsheet file or txt file or csv file?

Well, I don't know about you people, but I do! I know, I know, it sounds crazy! But it actually is faster than waiting for OpenOffice to load! :)

A .csv on plain sight?! I must be that guy who talks to a volleyball named Wilson or something.

In cases like these you might want to protect yourself from these baddies.

Well, I am going to share a little secret and that is how to keep a secret in Linux.

I am talking about file encryption, particularly the software called ccrypt.

ccrypt is based on the Rijndael cipher, which is the U.S. government's chosen candidate for the Advanced Encryption Standard

That sounds very nice doesn't it?

Let's get started:

1. Install ccrypt by:

$ sudo apt-get install ccrypt

2. Now change your directory where you want to keep your secret, or the directory where your password file is located.

For example:

$ cd /directoryname/topsecretfile.csv

3. Now type this:

$ ccrypt filename.csv

4. Then it will show this:

Enter encryption key:

5. Type or Enter your password/encryption key two times!

You're Done!

*filename.csv should now be named filename.csv.cpt

1. To decrypt, simple type this command:

$ ccrypt -d filename.csv.cpt

2. Then type your password/encryption key.