Posts Tagged ‘apache22’

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.

  1. # Configure LDAP auth helper
  2. 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
  3.  
  4. acl int-lan src 192.168.11.0/24
  5. acl daytime time M T W H F 08:30-12:30
  6. acl evening time M T W H F 13:30-17:30
  7.  
  8. 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.

  1. AuthType Basic
  2. AuthBasicProvider ldap
  3. AuthName "LDAP Secure Area"
  4. Require valid-user
  5. AuthLDAPBindDN "cn=username,ou=People,dc=domain,dc=org"
  6. AuthLDAPBindPassword XXXXXXXX
  7. AuthzLDAPAuthoritative off
  8. AuthLDAPCompareDNOnServer On
  9. 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

  1. WITHOUT_APACHE_OPTIONS= yes

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