From: michael+sup@stapelberg.de (Michael Stapelberg)
Subject: [sup-talk] Bug: Messages using inline GPG are not decrypted
Date: Sat, 26 Sep 2009 22:28:54 +0200 [thread overview]
Message-ID: <1253996823-sup-6670@midna.zekjur.net> (raw)
In-Reply-To: <1253988435-sup-8649@masanjin.net>
Hi,
Excerpts from William Morgan's message of Sa Sep 26 20:09:36 +0200 2009:
> I believe I've fixed this in git. Thunderbird is not producing
> RFC3156-compliant encrypted emails, but by the Postel's Law we will
> accomodate their errors. Let me know if it doesn't work.
The changes basically work. The message itself is opened and decrypted
correctly. However, when handling some messages, an exception occurs
(downcase called on NilClass), which can be fixed like this:
--- a/lib/sup/message.rb
+++ b/lib/sup/message.rb
@@ -436,7 +436,7 @@ private
end
chunks
- elsif m.header.content_type.downcase == "message/rfc822"
+ elsif m.header.content_type && m.header.content_type.downcase == "message/rfc822"
if m.body
payload = RMail::Parser.read(m.body)
from = payload.header.from.first ? payload.header.from.first.format : ""
@@ -456,7 +456,7 @@ private
debug "no body for message/rfc822 enclosure; skipping"
[]
end
- elsif m.header.content_type.downcase == "application/pgp" && m.body
+ elsif m.header.content_type && m.header.content_type.downcase == "application/pgp" && m.body
## apparently some versions of Thunderbird generate encryped email that
## does not follow RFC3156, e.g. messages with X-Enigmail-Version: 0.95.0
## they have no MIME multipart and just set the body content type to
Best regards,
Michael
next prev parent reply other threads:[~2009-09-26 20:28 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-09-22 17:05 Michael Stapelberg
2009-09-22 17:24 ` Michael Stapelberg
2009-09-25 19:10 ` Michael Stapelberg
2009-09-26 18:09 ` William Morgan
2009-09-26 20:28 ` Michael Stapelberg [this message]
2009-09-26 21:37 ` Ben Walton
2009-09-26 21:41 ` Michael Stapelberg
2009-09-27 1:40 ` 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=1253996823-sup-6670@midna.zekjur.net \
--to=michael+sup@stapelberg.de \
/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