imap4_SSL from behind a proxy server

Dave fkaanonymity at
Thu Jul 3 20:06:18 CEST 2008

First to admit I'm a newbie at Python, IMAP, or SSL.  And it's been a
long time since I've posted anything to a Usenet group.  But I've
spent countless hours spinning my wheels on this one, so I thought I'd
ask for help.

I'm trying write some Python code to connect to Gmail from work, where
I need to direct all non-HTTP traffic through a proxy server.  Can
anyone provide syntax which would redirect the imap4_SSL method
through a proxy server:port?  I suspect there are some environment
variables which, when set, will do this very easily and elegantly.  I
also suspect there is a really complicated way to 'wrap' the imap
classes so as to force requests to go through a proxy which, as a
newbie, I am trying to avoid.

FYI, I'm currently running Python 2.5.2. via IDLE on Windows XP.  But
when this project is done, I will move it to Linux.

Thanks for any help.

fkaprince, at Gmail, dot-com

More information about the Python-list mailing list