Get our free book (in Spanish or English) on rainwater now - To Catch the Rain.
Difference between revisions of "Encryption method: MOST"
m (Add remark about untrusted signatures.)
Latest revision as of 00:26, 11 July 2013
|By Michigan Tech's Open Sustainability Technology Lab.
Wanted: Students to make a distributed future with solar-powered open-source 3-D printing.
- 1 MOST Encryption method
- 1.1 Why do we want to use encryption?
- 1.2 When do we use encryption?
- 1.3 How does encryption work? A very short introduction
- 1.4 How do we use encryption? A step by step guide to set it up
- 1.5 Sending signed and encrypted e-mail
MOST Encryption method
This page describes how, when and why encrypted communication is used within the MOST group. Feel free to adopt these procedures for other projects. When editing this page, please only claim a different workflow if this has been adopted by the MOST group, or clearly mark it as a proposal.
Why do we want to use encryption?
We're developing open source appropriate technology, which means that our results will be as accessible as possible. We publish our hard- and software as open source, free for anybody to use. Still, we want to be able to use private means of communication in some cases. This deserves an explanation.
One reason is that in science, publication in peer-reviewed journals is important. If we would make all of our results available for download in advance, we run the risk that other people will claim them and preclude us from publishing a paper from our work. We do not want this, so some of our results must be kept secret until publication. (In the future this may not be as necessary as the world of peer review evolves and hopefully speeds up.)
Another reason is that we may want to discuss matters which really are private. It may be about family or health issues, for example. Sending e-mails with such information without encryption is like sending them on a postcard, and displaying it in the post office before it gets delivered. With encryption, the only thing that is displayed is the sender and receiver; it is like putting the message in a sealed envelope.
When do we use encryption?
One problem with communication is that many threads are being mixed into each other. While talking about one subject, it's natural to add a comment about another. Therefore, to prevent accidentally disclosing information that should be kept private, all e-mail communication must be encrypted.
Additionally, for sharing files which are too large to attach to an e-mail, or which we want to keep in a central place, we use a private revision control system which can only be reached through encrypted connections.
How does encryption work? A very short introduction
The technique we use is called public-key-encryption. The technique can be used for encrypting and signing (explained in a moment). With this system, every user needs to generate a so-called key-pair, consisting of a public key and a private key. The public key is published openly to all other people. The private key is kept strictly private. The encryption then uses mathematical algorithms on those keys and messages.
Encrypting a message is done using the message and a public key. The result of the encryption is a block of data which is unreadable. The original message can be extracted from this data by using the private key which corresponds to the public key that was used. This means that anybody can create the encrypted message (because everybody has the public key), but only the person owning the private key can decrypt and read it. This is what encryption wants to achieve.
Signing a message is done using a message and your private key. The result is an extra block of data, which can be shown in combination with the message and the corresponding public key, to be created with that private key. So this signature is cryptographic proof that can be checked by anyone, that the message was signed by the person with access to the private key. This is what we want a signature to mean.
So summarizing: a private key can be used to decrypt and sign messages, a public key can be used to encrypt a message and verify a signature.
How do we use encryption? A step by step guide to set it up
There are many ways to set up encryption. It's fine if you choose to use a different method. This is a procedure which works as simple as possible on Michigan Tech's campus network. If you have improvements which make things easier (without making them less secure), please let us know. Below is a step by step guide for computers which you maintain (as opposed to the MTU admins).
Setting it up running from a USB stick
This method works on any machine that runs Windows and allows you to run programs. It is currently the only method that works on MTU campus computers.
- Get a USB stick with at least 100 MB free space on it.
- Install Mozilla Thunderbird Portable on it. Note that you have to change the installation path to point to your USB stick.
- Start Thunderbird Portable (from the USB stick).
- Click the button for using an existing account, enter your name, MTU e-mail and ISO password and let Thunderbird figure everything out for you. After this step, you have set up thunderbird portable without encryption. The following steps will add encryption support.
- Close Thunderbird.
- Install GPG for Thunderbird Portable on top of Thunderbird Portable. Make sure you select the exact same folder that you selected for Thunderbird Portable for installing this to.
- In Thunderbird Portable, click on the three lines on the right of the search box to make the menu appear. Select Add-ons from this menu.
- Using the search box, search for the Enigmail add-on and install it.
- Thunderbird will request to be restarted. Do this.
- Open Thunderbird's menu again and select OpenPGP->Key management.
- From the top bar, select Generate->New key pair.
- Enter a passphrase, set the key to never expire and generate the key.
- If the window doesn't disappear after key generation (watch the progress bar), select cancel to close it.
- Select "Display all keys by default" in the key management window. Your new key should show up.
- Select your key, then from the menubar, select Keyserver->upload public keys. Accept the default key server.
- If you want to install your key on your own computer as well, right-click on it and select Export Keys to File, then select Export Secret Keys and save it to the USB stick. Do not send this file via e-mail!
- Close the Key management window.
- Open your account settings by selecting the account in the left bar, then clicking on View settings for this account.
- Select Composition & Addressing and uncheck Compose messages in HTML format.
- Select OpenPGP Security and check Enable OpenPGP security (Enigmail) for this identity, and all four checkboxes under Message Composition Default Options.
Setting it up on your own computer
- Install Mozilla Thunderbird and gnupg (Windows/Mac) on your machine. On GNU/Linux, install with your package manager instead of using the previous links. On Debian, note that Thunderbird is called Icedove.
- Follow all steps from the USB stick method, except for the ones installing software. You do need to get Enigmail.
- To import your key, select OpenPGP->Key Management from the Thunderbird menu, then select File->Import Keys from File.
Sending signed and encrypted e-mail
If the icons in the bottom right of the compose window are on, your mail will be encrypted and signed. If you don't have the key of the recipient, it will ask you what to do. You should always select Download missing keys and accept the default key server. It will pop up a window with too much information. Ignore all of it and click Ok. You then need to select the newly downloaded key and click Ok. If there is no key on the server, you cannot send this person encrypted e-mail. In that case, you must choose to either send it unencrypted or not send it.
When reading encrypted e-mail, Thunderbird will ask for your passphrase. After you enter it, you can read the e-mail. It will show a colored bar at the top of the message saying that this is a decrypted message. It will normally also say that it has an UNTRUSTED good signature. Don't worry about the untrusted part. If you're interested, you can get rid of it by building up a web of trust.