Skip to content

Store notebooks in an encrypted folder

shivams edited this page May 5, 2020 · 6 revisions

ENCFS

http://www.arg0.net/encfs

Available for linux users Encfs stores files in an encrypted folder. To read these files, they must be mounted to an empty directory.

1. Install encfs

This process varies depending on your linux distribution.

This example works for Arch Linux:

pacman -S encfs

Debian/Ubuntu:

apt-get install encfs

2. Move existing zim files

Important: Close Zim

mv ~/Notes Notes-old

3. Setup encfs folders

mkdir ~/.Notes

Hidden folder stores encrypted contents. Note the '.' dot.

mkdir ~/Notes

Same name as the folder Zim normally uses. Unencrypted files will be accessible here when mounted`

4. Start encryption

encfs ~/.Notes ~/Notes

this first time through, you will be prompted for a password, and some security settings. In the future, you will only need to supply a password. You will need to run this command each time you restart your computer before running zim

5. Move encrypt old notes

rsync -av ~/Notes-old ~/Notes

6. Remove old notes (optional)

Make sure zim starts normally and you can access your encrypted notebook first!

rm -rf ~/Notes-old

encfswrapper

encfswrapper can be used to automate the process of mounting an encfs folder when zim is run. A quick tutorial is in the README.rst file hosted at https://github.com/lenzenmi/encfswrapper.

Truecrypt Method with Cloud Synchronization

There is an interesting solution using Truecrypt and Dropbox. Your notebook can be encrypted inside a truecrypt container and that container can be synchronized over the cloud using Dropbox. The catch here is that when you open the container and make changes to your notebook and close it again, Dropbox wouldn't synchronize the whole container, only the bits that've changed.

Here is an automated solution for that in Linux : http://dotpad.blogspot.in/2012/12/zim-with-truecrypt-and-dropbox-my-final.html

UPDATE (2018-05-01):

Truecrypt is now no longer maintained. This method will still work, but adapt it to be used with Veracrypt : the Truecrypt alternative.

The method in the above-linked blog post uses a bash shell to manage Truecrypt/Veracrypt and Zim. The following gist does the same but uses a Python script instead: https://gist.github.com/jorgsk/721f15d03d21a847a0bfa9f4f4df60e6

Important Considerations when Encrypting Notebooks

In this section, we will be enlisting some important considerations and safety measures one should take while using encrypting notebooks:

Clone this wiki locally