It’s been a while since I’ve had to build an NTLM integrated Apache2 server.
So I thought I’d take help from Ubuntu’s packages and install LAMP from there like most people seem to be doing these days.
Once all that is up and running, you will need to download mod_ntlm_winbind. Its an ancient package I complied years ago from the samba source tree, good news is it still works.
Before we continue, double check you have the apache2-threaded-dev package installed
apt-get install apache2-threaded-dev
If you don’t, install it along with all the other required packages, most of them are quite useful on web development servers anyway.
This installs the apxs2 binary we need.
ln -s mod_ntlm_winbind.c mod_auth_ntlm_winbind.c
/usr/local/apache2/bin/apxs -DAPACHE2 -c -i mod_auth_ntlm_winbind.c
For activating it in the apache config, follow my previous guide, NTLM Authentication (Active Directory) on Apache (Linux).