Posts Tagged ‘apache’

LDAP authentication with Squid

Wednesday, December 14th, 2011

A snippet from squid.conf allowing LDAP authentication from Mon-Fri business hours. Done on Ubuntu 10.04.2 (lucid) and Squid 2.7.STABLE7.

# Configure LDAP auth helper
auth_param basic program /usr/lib/squid/ldap_auth -v 3 -b "ou=Int,ou=People,dc=domain,dc=org" -u "uid" -h ldaps.domain.org

acl int-lan src 192.168.11.0/24
acl daytime time M T W H F 08:30-12:30
acl evening time M T W H F 13:30-17:30

http_access allow ldapauth int-lan daytime evening

LDAP authentication with Apache

Monday, January 10th, 2011

A snippet from httpd.conf allowing LDAP authentication. Done on Ubuntu.

AuthType Basic
AuthBasicProvider ldap
AuthName "LDAP Secure Area"
Require valid-user
AuthLDAPBindDN "cn=username,ou=People,dc=domain,dc=org"
AuthLDAPBindPassword XXXXXXXX
AuthzLDAPAuthoritative off
AuthLDAPCompareDNOnServer On
AuthLDAPURL ldaps://ldaps.domain.org/ou=Internal,ou=People,dc=domain,dc=org?uid

How to disable configuration options while building Apache2 from ports

Tuesday, December 11th, 2007

According to http://www.freshports.org/www/apache22, OPTIONS support has been added on September 18, 2007 causing several knobs (like WITH_STATIC_MODULES) being ignored. In order to disable OPTIONS one should consider defining WITHOUT_APACHE_OPTIONS. Since I’m using portupgrade to do my regular ports maintenance I was trying to find where to put WITHOUT_APACHE_OPTIONS to make the change systemwide.

One of the options was to put it in /usr/ports/www/apache22/Makefile – it did work, but as soon as you update ports all changes will be overwritten. After some digging I finally figured out that putting

WITHOUT_APACHE_OPTIONS= yes

to /etc/make.conf will do the trick.