From 25ef1a0c09d59262bb271d0d9d738302bab6216e Mon Sep 17 00:00:00 2001 From: Thomas Jarosch Date: Fri, 13 Jul 2012 09:58:19 +0200 Subject: [PATCH] We documented we use SSL, so actually do it --- src/mail_iterator.py | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mail_iterator.py b/src/mail_iterator.py index 1f6f81c..6e3afdd 100644 --- a/src/mail_iterator.py +++ b/src/mail_iterator.py @@ -25,7 +25,7 @@ MAILBOX_RESP = re.compile(r'\((?P.*?)\) "(?P.*)" (?P.*)' #imaplib.Debug = 4 class MailIterator: - """This class communicates with the e-mail server.""" + """This class communicates with the IMAP server.""" # class attributes # IMAP4_SSL for connection with an IMAP server @@ -40,7 +40,7 @@ class MailIterator: # connect to server try: - self.mail_con = imaplib.IMAP4(server) + self.mail_con = imaplib.IMAP4_SSL(server) logging.info("Connected to %s", server) except socket.error as ex: logging.error("Could not connect to host: %s", ex) -- 1.7.1