From: tpo2@sourcepole.ch (Tomas Pospisek ML)
Subject: [sup-talk] improvement: add self as recipient on crypted sent messages
Date: Thu, 30 Oct 2008 17:03:45 +0000 [thread overview]
Message-ID: <7tCX6GnV.1225386225.8453510.tpo2@192.168.3.7> (raw)
In-Reply-To: <v0HRsyuE.1225375036.4997550.tpo2@192.168.3.7>
On 10/30/2008, "Tomas Pospisek ML" <tpo2 at sourcepole.ch> wrote:
>
>Currently sup seems to call gpg with the recipient only. However sup
>should add "self" also to the recipients. Otherwise one is not able to
>read sent, encrypted mails any more.
Patch is below. Two comments:
1. is there a less ugly way to create a new Array with an additional
element?
2. the patch assumes that adding "From: " to gpg's" --recipient"s is
a sensible thing to do and thus it does it with no questions asked
OK?
*t
--- sup/crypto.rb.orig 2008-10-30 16:36:37.000000000 +0100
+++ sup/crypto.rb 2008-10-30 17:40:07.000000000 +0100
@@ -53,7 +53,7 @@
payload_fn.write format_payload(payload)
payload_fn.close
- recipient_opts = to.map { |r| "--recipient '<#{r}>'" }.join("
")
+ recipient_opts = (to + [ from ] ).map { |r| "--recipient
'<#{r}>'" }.join(" ")
sign_opts = sign ? "--sign --local-user '#{from}'" : ""
gpg_output = run_gpg "--output - --armor --encrypt --textmode
#{sign_opts} #{recipient_opts} #{payload_fn.path}"
raise Error, (gpg_output || "gpg command failed: #{cmd}") unless
$?.success?
next prev parent reply other threads:[~2008-10-30 17:03 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-10-30 13:57 [sup-talk] improvement: add self as recipient on " Tomas Pospisek ML
2008-10-30 17:03 ` Tomas Pospisek ML [this message]
2008-11-02 19:30 ` [sup-talk] improvement: add self as recipient on crypted " William Morgan
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=7tCX6GnV.1225386225.8453510.tpo2@192.168.3.7 \
--to=tpo2@sourcepole.ch \
/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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox