Expand description
PGP support by shelling out to gpg(1): decrypt and verify messages for the pager, sign and encrypt outgoing drafts. Handles PGP/MIME (RFC 3156) and inline (“armor in the body”) messages. Passphrases are between gpg and its agent; rmut never sees or stores them.
Structs§
- Crypto
- Inspect a raw message; Some when it is PGP-encrypted or signed in any of the four shapes (PGP/MIME encrypted or signed, inline encrypted, clearsigned). Whether a message is signed and/or encrypted, without running gpg: just the MIME type and the inline PGP markers. For the reply-crypto defaults, which must not decrypt anything.
- Opened
- View
- What the pager should show for a PGP message: a replacement body (when decryption produced one) and a one-line status note. gpg trouble goes in the note; the original body stays available.
Enums§
- Body
- What decryption produced, when it produced anything.
- Sig
- Signature verdict from gpg’s –status-fd lines.
Functions§
- classify
- decrypt
- Decrypt an armored PGP message. Also accepts clearsigned input,
where gpg strips the armor and verifies instead. A bad signature is
reported in
sig, not as an error; the plaintext is still wanted. - encrypt
- Armored encryption of
datato every recipient address (gpg finds the keys), optionally signed in the same pass. –trust-model always mirrors mutt: keys are picked by address, not by web-of-trust. - encrypt_
entity - Like
encrypt_message, but over an arbitrary MIME entity. - encrypt_
message - Wrap a finalized draft in multipart/encrypted for
recipients(which the caller assembles from To/Cc/Bcc plus the sender, so the author can read their own mail);signadds a signature inside the encryption layer. Headers, including Subject, stay in clear. - sign_
detached - Detached armored signature over
data, plus the micalg parameter for the multipart/signed header. - sign_
entity - Wrap an arbitrary MIME entity (its own Content-Type header + body,
CRLF endings, e.g. compose::mixed_entity) in multipart/signed
under
head. - sign_
message - Wrap a finalized draft in multipart/signed.
flowedis mutt’s $text_flowed, passed through to the text part inside. - verify_
detached - Verify a detached signature over
data(already in the CRLF form it was signed in). gpg wants the signature as a file argument. - view