From: Daniel Kahn Gillmor <dkg@fifthhorseman.net>
To: Notmuch Mail <notmuch@notmuchmail.org>
Subject: [PATCH v2 14/21] cli/new, insert, reindex: update documentation for --decrypt=auto
Date: Thu, 30 Nov 2017 03:59:39 -0500 [thread overview]
Message-ID: <20171130085946.11332-15-dkg@fifthhorseman.net> (raw)
In-Reply-To: <20171130085946.11332-1-dkg@fifthhorseman.net>
we also include --decrypt=auto in the tab completion.
---
completion/notmuch-completion.bash | 6 +++---
doc/man1/notmuch-insert.rst | 16 ++++++++++------
doc/man1/notmuch-new.rst | 10 +++++++---
doc/man1/notmuch-reindex.rst | 23 ++++++++++++++---------
4 files changed, 34 insertions(+), 21 deletions(-)
diff --git a/completion/notmuch-completion.bash b/completion/notmuch-completion.bash
index f94dbeed..272131e6 100644
--- a/completion/notmuch-completion.bash
+++ b/completion/notmuch-completion.bash
@@ -288,7 +288,7 @@ _notmuch_insert()
return
;;
--decrypt)
- COMPREPLY=( $( compgen -W "true false" -- "${cur}" ) )
+ COMPREPLY=( $( compgen -W "true false auto" -- "${cur}" ) )
return
;;
esac
@@ -320,7 +320,7 @@ _notmuch_new()
$split &&
case "${prev}" in
--decrypt)
- COMPREPLY=( $( compgen -W "true false" -- "${cur}" ) )
+ COMPREPLY=( $( compgen -W "true false auto" -- "${cur}" ) )
return
;;
esac
@@ -442,7 +442,7 @@ _notmuch_reindex()
$split &&
case "${prev}" in
--decrypt)
- COMPREPLY=( $( compgen -W "true false" -- "${cur}" ) )
+ COMPREPLY=( $( compgen -W "true false auto" -- "${cur}" ) )
return
;;
esac
diff --git a/doc/man1/notmuch-insert.rst b/doc/man1/notmuch-insert.rst
index eb9ff11b..b22be863 100644
--- a/doc/man1/notmuch-insert.rst
+++ b/doc/man1/notmuch-insert.rst
@@ -51,14 +51,18 @@ Supported options for **insert** include
``--no-hooks``
Prevent hooks from being run.
- ``--decrypt=(true|false)``
+ ``--decrypt=(true|auto|false)``
- If true and the message is encrypted, try to decrypt the
- message while indexing. If decryption is successful, index
+ If ``true`` and the message is encrypted, try to decrypt the
+ message while indexing. If ``auto``, and notmuch already
+ knows about a session key for the message, it will try
+ decrypting using that session key but will not try to access
+ the user's secret keys. If decryption is successful, index
the cleartext itself. Either way, the message is always
- stored to disk in its original form (ciphertext). Be aware
- that the index is likely sufficient to reconstruct the
- cleartext of the message itself, so please ensure that the
+ stored to disk in its original form (ciphertext).
+
+ Be aware that the index is likely sufficient to reconstruct
+ the cleartext of the message itself, so please ensure that the
notmuch message index is adequately protected. DO NOT USE
``--decrypt=true`` without considering the security of
your index.
diff --git a/doc/man1/notmuch-new.rst b/doc/man1/notmuch-new.rst
index 1df86f06..71df31d7 100644
--- a/doc/man1/notmuch-new.rst
+++ b/doc/man1/notmuch-new.rst
@@ -43,11 +43,15 @@ Supported options for **new** include
``--quiet``
Do not print progress or results.
- ``--decrypt=(true|false)``
+ ``--decrypt=(true|auto|false)``
- If true, when encountering an encrypted message, try to
+ If ``true``, when encountering an encrypted message, try to
decrypt it while indexing. If decryption is successful, index
- the cleartext itself. Be aware that the index is likely
+ the cleartext itself. If ``auto``, try to use any session key
+ already known to belong to this message, but do not attempt to
+ use the user's secret keys.
+
+ Be aware that the index is likely
sufficient to reconstruct the cleartext of the message itself,
so please ensure that the notmuch message index is adequately
protected. DO NOT USE ``--decrypt=true`` without
diff --git a/doc/man1/notmuch-reindex.rst b/doc/man1/notmuch-reindex.rst
index 782b0d7b..d87e9d85 100644
--- a/doc/man1/notmuch-reindex.rst
+++ b/doc/man1/notmuch-reindex.rst
@@ -21,15 +21,20 @@ messages using the supplied options.
Supported options for **reindex** include
- ``--decrypt=(true|false)``
-
- If true, when encountering an encrypted message, try to
- decrypt it while reindexing. If decryption is successful,
- index the cleartext itself. Be aware that the index is likely
- sufficient to reconstruct the cleartext of the message itself,
- so please ensure that the notmuch message index is adequately
- protected. DO NOT USE ``--decrypt=true`` without
- considering the security of your index.
+ ``--decrypt=(true|auto|false)``
+
+ If ``true``, when encountering an encrypted message, try to
+ decrypt it while reindexing. If ``auto``, and notmuch already
+ knows about a session key for the message, it will try
+ decrypting using that session key but will not try to access
+ the user's secret keys. If decryption is successful, index
+ the cleartext itself.
+
+ Be aware that the index is likely sufficient to reconstruct
+ the cleartext of the message itself, so please ensure that the
+ notmuch message index is adequately protected. DO NOT USE
+ ``--decrypt=true`` without considering the security of your
+ index.
See also ``index.decrypt`` in **notmuch-config(1)**.
--
2.15.0
next prev parent reply other threads:[~2017-11-30 9:00 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-30 8:59 session keys, version 2 Daniel Kahn Gillmor
2017-11-30 8:59 ` [PATCH v2 01/21] mime-node: handle decrypt_result more safely Daniel Kahn Gillmor
2017-11-30 8:59 ` [PATCH v2 02/21] crypto: add _notmuch_crypto_decrypt wrapper function Daniel Kahn Gillmor
2017-11-30 8:59 ` [PATCH v2 03/21] configure: session key handling in gmime maps to built_with("session_key") Daniel Kahn Gillmor
2017-11-30 8:59 ` [PATCH v2 04/21] crypto: use stashed session-key properties for decryption, if available Daniel Kahn Gillmor
2017-11-30 15:06 ` Daniel Kahn Gillmor
2017-12-05 1:47 ` David Bremner
2017-11-30 8:59 ` [PATCH v2 05/21] test/corpora: add an encrypted message for index decryption tests Daniel Kahn Gillmor
2017-11-30 8:59 ` [PATCH v2 06/21] crypto: Test restore of cleartext index from stashed session keys Daniel Kahn Gillmor
2017-12-05 1:59 ` David Bremner
2017-12-06 2:12 ` Daniel Kahn Gillmor
2017-12-07 8:20 ` Jameson Graef Rollins
2017-12-08 7:03 ` Daniel Kahn Gillmor
2017-11-30 8:59 ` [PATCH v2 07/21] indexing: Change from try_decrypt to decrypt Daniel Kahn Gillmor
2017-11-30 8:59 ` [PATCH v2 08/21] indexopts: change _try_decrypt to _decrypt_policy Daniel Kahn Gillmor
2017-11-30 8:59 ` [PATCH v2 09/21] lib: convert notmuch decryption policy to an enum Daniel Kahn Gillmor
2017-11-30 8:59 ` [PATCH v2 10/21] crypto: new decryption policy "auto" Daniel Kahn Gillmor
2017-11-30 8:59 ` [PATCH v2 11/21] cli/reply: use decryption policy "auto" by default Daniel Kahn Gillmor
2017-11-30 8:59 ` [PATCH v2 12/21] cli/show: " Daniel Kahn Gillmor
2017-11-30 8:59 ` [PATCH v2 13/21] cli/show, reply: document use of stashed session keys in notmuch-properties Daniel Kahn Gillmor
2017-11-30 8:59 ` Daniel Kahn Gillmor [this message]
2017-11-30 8:59 ` [PATCH v2 15/21] crypto: record whether an actual decryption attempt happened Daniel Kahn Gillmor
2017-11-30 8:59 ` [PATCH v2 16/21] cli/new, insert, reindex: change index.decrypt to "auto" by default Daniel Kahn Gillmor
2017-11-30 8:59 ` [PATCH v2 17/21] cli/reindex: destroy stashed session keys when --decrypt=false Daniel Kahn Gillmor
2017-11-30 8:59 ` [PATCH v2 18/21] crypto: actually stash session keys when decrypt=true Daniel Kahn Gillmor
2017-11-30 8:59 ` [PATCH v2 19/21] crypto: add --decrypt=nostash to avoid stashing session keys Daniel Kahn Gillmor
2017-11-30 8:59 ` [PATCH v2 20/21] docs: clean up documentation about decryption policies Daniel Kahn Gillmor
2017-11-30 8:59 ` [PATCH v2 21/21] python: add decrypt_policy argument to Database.index_file() Daniel Kahn Gillmor
2017-11-30 15:05 ` Daniel Kahn Gillmor
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://notmuchmail.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20171130085946.11332-15-dkg@fifthhorseman.net \
--to=dkg@fifthhorseman.net \
--cc=notmuch@notmuchmail.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://yhetil.org/notmuch.git/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).