|back to the howto main page|
setting up ldap |  ldap and apache |  ldap and samba |  ldap and squid |

Howto: LDAP User Authentication on Squid Servers

You should've set up a working LDAP-environment (howto set up LDAP). If you've set up a working squid environment - the better! Check your version of squid - here it's the etch-version 2.6.STABLE5.

My fresh installation of squid says that I should set the visible-hostname entry first.
With a working DNS-environment you may not encounter that failure. The installed squid.conf on Debian systems can be found in /etc/squid.
(the debian squid creates its swap directories automatically - ergo no squid -z for me)

Okay. some preparations that squid works and off we go!
To check if LDAP Authentication is possible - squid brings along its own authentication tool. It can be found in /usr/lib/squid/ldap_auth.

# ./ldap_auth -v3 -b "dc=killme,dc=rec" -f "(uid=%s)"

Where -b is our search base (dn) -v3 the LDAP Version and -f is our filter to check for the users uid (most important part). You'll see nothing but the blinking cursor waiting for you to give him ldap-username username's-password.
(german forum entry about the failure in testing can be found at http://www.ubuntuusers.de)

The check succeeds and we're about to enter the authentication in our squid.conf. We have to comment in all the auth_param basic entries and have to create both acl and http_access rules.

Let Squid reread its configuration,

and authorize at squid. And off you go! :D

'Would you pay last pleasure to see me ?'
The Fields of the Nephilim - Last Exit for the Lost (1988)