Opened 9 years ago

Closed 9 years ago

Last modified 5 years ago

#5697 enhancement closed fixed (fixed)

Make the mail example compatible with servers require SSL

Reported by: argonemyth Owned by: Itamar Turner-Trauring
Priority: normal Milestone:
Component: mail Keywords: documentation, example
Cc: jesstess Branch: branches/imap-example-5697
branch-diff, diff-cov, branch-cov, buildbot
Author: itamarst


The example only works with an IMAP server that doesn't require SSL. The script hangs if you try to access servers like I guess a lot of people might try Gmail with this script, it's better to make it compatible with servers that require SSL.

The script should also stop the reactor once the job is finished.

Attachments (1)

5697-imap4client-20120612.patch (7.0 KB) - added by argonemyth 9 years ago.

Download all attachments as: .zip

Change History (6)

comment:1 Changed 9 years ago by argonemyth

Keywords: review added
Owner: argonemyth deleted

The main reason why it hangs when you try to connect to a Gmail account is that it doesn't initiate a SSL connection if you only change the port number to 993. I fixed the issue by using reactor.connectSSL if an user input '993' as the port number.

A note on Gmail! It's been using 'XOAUTH' as authentication method since 2010. So, only 'clear-text' (the insecure way) is available for gmail accounts. I tested the script on an IMAP server that supports PLAIN auth, worked well.

I also modified the example a bit to fit the coding standard. Please review (5697-imap4client-20120612.patch), Thanks!

Changed 9 years ago by argonemyth

comment:2 Changed 9 years ago by Itamar Turner-Trauring

Owner: set to Itamar Turner-Trauring

comment:3 Changed 9 years ago by itamarst

Author: itamarst
Branch: branches/imap-example-5697

(In [34752]) Branching to 'imap-example-5697'

comment:4 Changed 9 years ago by itamarst

Resolution: fixed
Status: newclosed

(In [34756]) Merge imap-example-5697: Improvements to the IMAP client example.

Author: argonemyth Reviewer: itamar Fixes: #5697

comment:5 Changed 5 years ago by hawkowl

Keywords: review removed

[mass edit] Removing review from closed tickets.

Note: See TracTickets for help on using tickets.