2/24/09
Secure Forms Part 1, Install GPG
This is part one of a series of tutorials demonstrating how to setup a secure online form for your website. We will be using the GNU Privacy Guard (GPG or GnuPG) to encrypt and decrypt the messages for us. GPG is a complete and free implementation of the OpenPGP standard. Today we will look at how to setup GPG on our personal computer.
We must have GPG installed locally to decrypt the messages that we’ll be receiving from our online form. We’ll also need a mail reader that can work with GPG, but we’ll cover that in a future lesson. Finally, although I personally use Linux, I’m going to be showing you how to set this up on a Windows XP machine.
First, we need to download GPG. The exact file we need is called gnupg-w32cli-1.4.9.exe and can be found at ftp://ftp.gnupg.org/gcrypt/binary/
Once it’s finished downloading, we’ll go ahead and install it. First, we’ll choose a language.

Choose a Language
Then we’ll start the installation by clicking Next.

Start the Installation
To continue with the installation, we have to agree to the GNU General Public License.

GNU General Public License
I don’t need support for languages other than English, so I’ve unchecked the NLS option. If you need support for other languages, leave the NLS option checked. I’ve left the Tools and Documentation options checked.

GPG Options
I’ll be installing GPG to it’s default location. While you are free to change this, be warned that you’ll have to modify some of the instructions later on if you choose a different location.

GPG Location
Next it will ask us to choose our preferred start menu folder for GPG. I accepted the default start menu folder, but feel free to change this if you’d like. Then click Install. When the installation is complete, click Next. Then choose whether on not you want to view the README file, and click Finish.
Now that we have GPG installed, we need to let Windows know where it’s stored so that other programs (such as Thuderbird) can access it. To do that, we’ll open the Start Menu, right-click on My Computer, and choose Properties. Under the Advanced tab, choose Environment Variables near the bottom.

Environment Variables
In the System Variables section, locate the Path variable. Click it once, and choose Edit.

Add a New Path
At the end of Variable value, add “;C:\Program Files\GNU\GnuPG” and click OK. A few notes on this step. First, the semi-colon at the begining is not a typo. You’ll need it there. Second, make sure you don’t leave a trailing space at the end of the line. Finally, if you decided to install GPG somewhere other than the default location, you will need to enter the path to the location you specified. However, if you used the default location (as I did in the example) you should be fine following my instructions to the letter.

Add GPG to Paths
Click OK on the Environmental Variables window, and then OK in the System Properties window. We should now be ready to use GPG. Just to make sure, we’ll run a quick little test. GPG is a command line program, so click the Start button and choose Run… Then type cmd and hit Enter. Now we should be ready to run some commands. To check what version of GPG is installed (and to make sure that it installed properly) type gpg –version and hit enter. You should see something like this:
Alright, that’s it for this lesson. In Secure Forms - Part 2 we’ll start learning how to actually use the program.
If you found this tutorial useful, or if you have any questions about this subject, please leave a comment below.
Posted in Security | No Comments »

