Subject: [sup-devel] [PATCH] Stop double quoting the protocol when sending encrypted emails

From: Hamish D <[email-masked]>
Date: Fri, 22 Oct 2010 16:37:58 +0100

Some friends of mine were having trouble with encrypted messages of
mine sent by sup. From the commit message:

Stop double quoting the protocol when sending encrypted emails

It was the case that when encrypting emails, the content-type
header line would look like:
Content-Type: multipart/encrypted;
boundary="=-1287680456-54319-281-6673-1-=";
protocol=""application/pgp-encrypted""
It appears that rmail adds the extra quotes, so this change
makes the protocol unquoted to start with, so we end up with
correct quoting.

Hamish Downer
From 85a532b6f7e598b5cfde34b221992d5a3f90733f Mon Sep 17 00:00:00 2001
From: Hamish Downer <[email-masked]>
Date: Fri, 22 Oct 2010 16:18:10 +0100
Subject: [PATCH] Stop double quoting the protocol when sending encrypted emails

It was the case that when encrypting emails, the content-type
header line would look like:
Content-Type: multipart/encrypted; boundary="=-1287680456-54319-281-6673-1-="; protocol=""application/pgp-encrypted""
It appears that rmail adds the extra quotes, so this change
makes the protocol unquoted to start with, so we end up with
correct quoting.
---
 lib/sup/crypto.rb |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/lib/sup/crypto.rb b/lib/sup/crypto.rb
index bce01d1..c7b57c1 100644
--- a/lib/sup/crypto.rb
+++ b/lib/sup/crypto.rb
@@ -88,7 +88,7 @@ EOS
     control.body = "Version: 1\n"
 
     envelope = RMail::Message.new
-    envelope.header["Content-Type"] = 'multipart/encrypted; protocol="application/pgp-encrypted"'
+    envelope.header["Content-Type"] = 'multipart/encrypted; protocol=application/pgp-encrypted'
 
     envelope.add_part control
     envelope.add_part encrypted_payload
-- 
1.7.1

_______________________________________________
Sup-devel mailing list
[email-masked]
http://rubyforge.org/mailman/listinfo/sup-devel

---

From: Rich Lane <[email-masked]>
Date: Thu, 04 Nov 2010 12:04:49 -0400

Applied to master.