From c1efe1dfb255f155306952bd2320f56a807a5c01 Mon Sep 17 00:00:00 2001
From: Kali Kaneko <kali@leap.se>
Date: Tue, 26 Apr 2016 22:55:40 -0400
Subject: [bug] cast the identity to bytes

This fixes a bug in which the tls transport complains about receiving
unicode. It was only made evident by running against twisted 16.
---
 src/leap/mail/outgoing/service.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'src/leap')

diff --git a/src/leap/mail/outgoing/service.py b/src/leap/mail/outgoing/service.py
index 335cae4..95d3e79 100644
--- a/src/leap/mail/outgoing/service.py
+++ b/src/leap/mail/outgoing/service.py
@@ -224,7 +224,7 @@ class OutgoingMail(object):
             heloFallback=True,
             requireAuthentication=False,
             requireTransportSecurity=True)
-        factory.domain = __version__
+        factory.domain = bytes('leap.mail-' + __version__)
         emit_async(catalog.SMTP_SEND_MESSAGE_START,
                    self._from_address, recipient.dest.addrstr)
         reactor.connectSSL(
-- 
cgit v1.2.3


From 3e33718164d91bb281c7d70b82c178a147f7cc39 Mon Sep 17 00:00:00 2001
From: Kali Kaneko <kali@leap.se>
Date: Wed, 11 May 2016 13:50:25 -0400
Subject: [bug] Allow pixelated integration not to interfere with thunderbird

One of the pixelated adaptors was trying to access a non-existing
attribute in HashableMailbox, which for some reason was blocking the
operation of the imap server (uncatched exception in listeners call
maybe).

adding an attribute skips this error and therefore allows seamless use
of both pixelated and thunderbird user agents at the same time.

Resolves: #8083
---
 src/leap/mail/imap/mailbox.py | 3 +++
 1 file changed, 3 insertions(+)

(limited to 'src/leap')

diff --git a/src/leap/mail/imap/mailbox.py b/src/leap/mail/imap/mailbox.py
index d545c00..e70a1d8 100644
--- a/src/leap/mail/imap/mailbox.py
+++ b/src/leap/mail/imap/mailbox.py
@@ -91,6 +91,9 @@ def make_collection_listener(mailbox):
         def __init__(self, mbox):
             self.mbox = mbox
 
+            # See #8083, pixelated adaptor seems to be misusing this class.
+            self.mailbox_name = self.mbox.mbox_name
+
         def __hash__(self):
             return hash(self.mbox.mbox_name)
 
-- 
cgit v1.2.3