Squid authentication via POP or IMAP
A short tutorial explaining how to make Squid validate its users against a POP or IMAP server. It must be useful, because I use it ;-)
A short tutorial explaining how to make Squid validate its users against a POP or IMAP server. It must be useful, because I use it ;-)
Thanks for this write up, but could you please update it so it uses the syntax of Squid 2.5?
It took me some time before I figured out why it complained so much about it :-)
Edwin
Done. It took me a while because I didn't notice your comment until yesterday ;-)
Hi!
I am kind of new in working with linux and I have a problem about connecting a windows email client (outlook express)to an external mail server on pop3. Does your script help me do that?
I am runnig Linux FC1 with squid 2.5 stable 5 and made all the configurations you described but still receive the same error from outlook (cannot connect to server xxxx). The proxy settings are in place on windows as everything else works just fine via squid.
Thanks for your time.
Sorry, but your problem is much deeper than you think.
* Squid has nothing to do with mail, really. It only handles access to webpages and FTP servers.
* This script and config is about using a password to access squid, and uses an email server as a way to check if the password is correct. It has nothing to do with reading mail at all.
* What you want is probably a NATing firewall, or at least a POP3 proxy.
If you want, email me and I can try to give you a hand, but if this is for your work, what you really need to do is hire someone who knows networking to gie you a hand.
Hi!
I have a problem, script output is under
Traceback (most recent call last):
File "popauth.py", line 21, in ?
[user,password]=line.split(' ')
ValueError: unpack list of wrong size
How can i do?
Huso: that shouldn't happen. It means that squid is passing malformed data to the script.
Specifically, it means that there is extra space (or a missing space) in the authentication data.
Please contact me via email!
Hints for making a version of the script to work with ssl pop3 (port 995)?
LucA: well, you could use openssl (the command) to wrap a SSL connection into a call to os.popen.
Or you could use a python-ssl module, which I am sure is out there somewhere.
Thank you, you are the man...