Skip to content

Commit

Permalink
Minor Documentation Fixes (#425)
Browse files Browse the repository at this point in the history
* Update installation.rst

* minor fixes to encryption.rst

instruct user to set `HISTIGNORE` while maintaining their existing `HISTIGNORE`
minor whitespace change
  • Loading branch information
asauber authored and maebert committed May 17, 2016
1 parent c25e6f3 commit 43658c1
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions docs/encryption.rst
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ A note on security

While jrnl follows best practises, true security is an illusion. Specifically, jrnl will leave traces in your memory and your shell history -- it's meant to keep journals secure in transit, for example when storing it on an `untrusted <http://techcrunch.com/2014/04/09/condoleezza-rice-joins-dropboxs-board/>`_ services such as Dropbox. If you're concerned about security, disable history logging for journal in your ``.bashrc`` ::

HISTIGNORE="jrnl *"
HISTIGNORE="$HISTIGNORE:jrnl *"

If you are using zsh instead of bash, you can get the same behaviour adding this to your ``zshrc`` ::

Expand All @@ -40,7 +40,7 @@ If you are using zsh instead of bash, you can get the same behaviour adding this
Manual decryption
-----------------

Should you ever want to decrypt your journal manually, you can do so with any program that supports the AES algorithm in CBC. The key used for encryption is the SHA-256-hash of your password, the IV (initialisation vector) is stored in the first 16 bytes of the encrypted file. The plain text is encoded in UTF-8 and padded according to PKCS#7 before being encrypted. So, to decrypt a journal file in python, run::
Should you ever want to decrypt your journal manually, you can do so with any program that supports the AES algorithm in CBC. The key used for encryption is the SHA-256-hash of your password, the IV (initialisation vector) is stored in the first 16 bytes of the encrypted file. The plain text is encoded in UTF-8 and padded according to PKCS#7 before being encrypted. So, to decrypt a journal file in python, run ::

import hashlib, Crypto.Cipher
key = hashlib.sha256(my_password).digest()
Expand Down
2 changes: 1 addition & 1 deletion docs/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ to install the dependencies for encrypting journals as well.

Installing the encryption library, `pycrypto`, requires a `gcc` compiler. For this reason, jrnl will not install `pycrypto` unless explicitly told so like this. You can `install PyCrypto manually <https://www.dlitz.net/software/pycrypto/>`_ first or install it with ``pip install pycrypto`` if you have a `gcc` compiler.

Also note that when using zsh, you the correct syntax is ``pip install "jrnl[encrypted]"`` (note the quotes).
Also note that when using zsh, the correct syntax is ``pip install "jrnl[encrypted]"`` (note the quotes).

The first time you run ``jrnl`` you will be asked where your journal file should be created and whether you wish to encrypt it.

Expand Down

0 comments on commit 43658c1

Please sign in to comment.