вторник, 15 января 2013 г.

Gnupg PGP encryption for XXXXS


I think its pretty important that we all wise up to security now that we time and time again are betrayed by such services such as hushmail. Bellow is a tutorial Ive written on how to use gnupg, it is meant to be understood by anyone from 12 year olds to 70 year olds so if anyone has any ideas on how to improve it to make more easily understood or if Ive missed something please contact me.



Gnupg is a free PGP encryption program licensed under gnu. This guide assumed youre using the windows version. To start using this program first you go and download it from: www.gnupg.org

Then you install it pretty simple procedure.

Next you need to create an encryption key. For every encryption key you create you get a secret key that you need to decrypt messages other people send to you. You should keep your secret key secret and not share it. You also get a public key that other people need to encrypt stuff they want to send you.

To create a key you use the following command:

gpg --gen-key

It will ask you what kind of key you want. I use the default
"(1) DSA and Elgamal" and suggest you do too.

Next it asks how many bits you want your key to be. I use 4096, which is maximum and the most secure.

Next it will ask when the key expire. You can make a new key any
time you want so if you dont want any hassles you should just
choose "0 = key does not expire"


At last it will ask you your "realname", "email" and "comment" and you can just type afdhgfhs jfdjdf@dhfhd.com, it dont matter.

Next it will ask you for a password. It is important you pick a long and tricky one. Maybe some lyrics from a favority song in El1t3 text.

Now the program will create the key which takes some time because it need to generate random data. Play a game or do something else on the computer and it will go faster. When its done you got your key. Now you need to print the public key on your screen so you can share it with others that want to send you encrypted stuff.

Use this command to print your public key on your screen. Right-click and select mark, mark the text and right-click again, open up notepad and paste it, save and you got your public key to share with others.

gpg --export --armor


When you have received the public key of someone else you save it in a file in the same folder as gpg.exe and type the following command to save it.

gpg --import [filename]


Usually if the name of the file containing the key you are importing is named user1.txt or user1.gpg the name identifying the key to gnupgp will be user1. So in that case you will type the following command in order to encrypt a file for the guy who whose key you imported in the user1.txt file.

gpg -e -r user1 file.txt

When using this command gpg will create a new encrypted file that only user1 can open ready for you to send to user1.

To decrypt something someone sent to you you put the file in the same directory as gpg.exe and type:

gpg [filename]

You will be prompted for your password and once entered you will get a new file which is the decrypted version of the file.

There you go, now you can send and receive truely encrypted email, no longer having to put trust in hushmail, safemail and the likes. To learn more you can read the readme.txt or http://www.gnupg.org/documentation/howtos.html

UPDATE:

Heres what you do to create encrypt text in pgp to a format which can be pasted in notepad and emails. No need to send it as attachment. Type the following command:

gpg -ear receiver message.txt

It will output a file called message.txt.asc which contains just ascii text. Then you can email that text to to anyone they in turn will save the message to a file like message.txt.gpg and decrypt it using the method described above.

Комментариев нет:

Отправить комментарий