Protecting the contents of the profile - mail
From MozillaZine Knowledge Base
- This article was written for Thunderbird but also applies to Mozilla Suite / SeaMonkey (though some menu sequences may differ).
Messages are stored in text files within your profile folder. Somebody else could read them using Thunderbird or by viewing the appropiate file with a text editor. If you want to prevent this the first thing you need to do is decide how much effort to protect your messages is appropiate. The easiest option is to password-protect the profile with an extension, but this is trivial to bypass.
Several methods to consider:
- The ProfilePassword extension requires a user to enter a password in order to use the profile. It is trivial to bypass by running in safe mode (to disable the extension) or by using a text editor such as Notepad to read the text files that Thunderbird stores the messages in. This method may be sufficient if other people accessing the same computer are not technical or if they are unlikely to deliberately snoop.
- The master password is meant to protect your stored passwords, not your profile. If you configure one it will prompt the user for a master password when they run Thunderbird. However, if you press the X control or the cancel button three times its replaced by a prompt for the accounts password , which you can cancel. This method is not recommended, but some users might find it sufficient for casual snoopers. Another solution would be to use a free password manager that can auto-type passwords such as Keepass. The Keepass Helper add-on "Adds a hostname, URL, or email account ID to the application's window name (e.g., that of Firefox or Thunderbird) to make it recognizable to password manager utilities like KeePass."
- If you have multiple users on a machine, create a separate Windows user account for each person. Typically this will prevent anybody without admin privileges on that PC from accessing your profile. The easiest way for somebody to bypass that would be to boot another operating system using a bootable rescue CD or flash drive.
- Use operating system commands to restrict access to the files. For example, if you store your profile on a NTFS partition you can right-click on the folder in Windows Explorer, select Properties, the Security tab, and then specify who has access to that folder. That can be bypassed by somebody else with admin privileges, or by booting another operating system using a live CD such as Knoppix. In a business environment an admin might consider using group or system policy settings to restrict access or store it in a password-protected file share on a file server.
- The Professional version of Windows 2000 and later versions of Windows supports encrypting files and folders on NTFS volumes using EFS (encrypted file system). Right click on the profile folder in Windows Explorer, select Properties, Advanced, check "Encrypt contents to secure data" and then press the Apply button. One risk is that another user with admin privileges can decrypt a folder by modifying the Data Recovery Agent configuration and just wait for you to login again. Encrypting a folder doesn't prevent somebody from deleting it or listing its contents so you may want to set the NTFS permissions to prevent that (as described in the preceding paragraph).
- Store the profile on a password-protected encrypted disk partition. You want to use a encrypted disk partition to avoid being prompted to encrypt and decrypt each file. You don't necessarily have to use a real partition, typically this type of software also supports file containers, a way to make to make a file act like a partition. If the profile already exists, move it per these instructions.
- TrueCrypt used to be the most frequently recommended solution due to its good reputation and it supporting Windows, OS X and Linux. Its unclear why the original project suddenly shut down in a bizarre way May 28, 2014, replacing version 7.1a with a version 7.2 that only lets you decrypt existing disk partitions. Verified copies of 7.1a are available at a mirror provided by the OpenSource Audit Project. VeraCrypt is a fork of TrueCrypt that supposedly fixes “all the serious security issues and weaknesses found so far in the source code” by the Open Crypto Audit Project. There are a couple of other replacements such as TCnext and CipherShed but they are nowhere near as popular as VeraCrypt.
- Diskcryptor was originally compatible with TrueCrypt but now supports its own format. It supports many configuration options for booting an encrypted operating system , supports Windows LiveCD, and has full support for external storage devices. Its only available for XP and later versions of MS Windows.
- Symantec (they bought PGP) sells PGP whole disk encryption (encrypts entire disk) and PGP Desktop Email (encrypts just your mail). Thunderbird's built-in S/MIME support or the Enigmail (OpenPGP add-on) are free alternatives to PGP Desktop Email. The main problem with protecting your mail by sending and receiving encrypted messages is that you might be willing to deal with the hassles, but most people won't. You will typically have a mixture of encrypted and unprotected messages.
- There is nothing necessarily wrong with the following solutions, but they don't have the same reputation:
- The combination of Rohos Mini Drive and Rohos Disk Browser supports on the fly encryption of FAT32/NTFS partitions on USB flash drives without requiring admin privileges. It might be the best choice for a roaming Windows user. See  and  for more information.
- If you just want to secure the contents of one folder and don't normally use the Local Folders special account you could move the messages you want to protect there and with one click in windows explorer encrypt/decrypt the mbox file containing those messages using either Axcrypt or AES Crypt. A "inbox" mail folder would have a "inbox." mbox file that contains the messages, a "inbox.msf" file that is a cache of the folder listing (if its deleted Thunderbird will automatically re-create it) and a inbox.sbd child directory used to organize any other child folders into a folder hierarchy. The "Local Folders" special account doesn't know how to check for new mail so nothing is going to notice that the mbox file is encrypted until you explicitly open that folder. Trying to open it should fail, but not harm anything. Some quick experimentation using a encrypted folder that has copies of messages that you don't care about should prove that one way or another.
- If you're fanatical about privacy:
- Think about where your temporary files are stored. Thunderbird creates two temporary files when sending a message, and sometimes creates others in a MozillaMailnews subdirectory (in that directory). Opening an attachment will also typically create a temporary file. Under Windows you can set the TMP and TEMP environmental variables to point to where temporary files should be created. You might set it to a small RAM disk or a directory in an existing password-protected encrypted disk partition.
- If you delete a message stored in your POP account or Local Folders directory the original message is still in that folder (just hidden from view and marked for deletion). When you compact a folder it physically deletes the "deleted" messages. It creates a temporary "nstmp" file and then deletes it when it does this. You'd need to use a secure data removal tool to prevent somebody from using a disk editor to read the sectors used to store those messages. However, if you stored the profile on a password-protected encrypted disk partition the messages in the freed sectors should still be encrypted, not clear text.
- A IMAP account stores the headers for each folder in mail summary files on the hard disk. The *.msf files contain the subject and the email addresses for each message. One way to automatically remove those files would be to modify the Thunderbird shortcut to launch a batch file, and have it cleanup when you exit Thunderbird. The first line would launch Thunderbird. The second line could contain something like del accounts_pathname\*.msf /S to delete all of the *.msf files in the IMAP account directory in the profile. Doing this will force Thunderbird to fetch the headers for any remote folder you open (such as the inbox folder) the next time you run it.
- Don't forget about the optional disk cache (Cache directory), offline folders (OfflineCache directory), search index (globl-message-db.sqlite) and *.wdseml files (Windows Search Integration) in the profile. Deleting an account doesn't delete its messages, it just makes Thunderbird forget about that account
- There are products such as Passware Kit Forensic that can within an hour decrypt hard drives encrypted using BitLocker, FileVault and TrueCrypt. It can also recover passwords for PGP virtual disks and Mac keychain files. It doesn't 'break' the encryption, it does a memory dump to extract the keys while the user is logged in. This type of attack has been known for a long while and doesn't work if you power off rather than leave the computer in sleep mode, or dismount the volume.  
Some lists of links