debian 6 (squeeze), apache2, mod_ntlm

Еще немного ретро:

Debian squeeze (6), apache 2.2.
Для NTLM аутентификации понадобился модуль mod_ntlm.
Линк
Под apache 2 соответственно линк
Далее
tar xvf mod_ntlm2.tar.gz
cd mod_ntlm2/
sudo apxs2 -i -a -c mod_ntlm.c
чтобы появился apxs2 нужно поставить apache2-prefork-dev
sudo aptitude install apache2-prefork-dev

Осталось внести изменения в конфиг apache (настройка VirtualHost/Directory) и перезапустить apache.



Пример отсюда и кусочек документации:

<VirtualHost *:80>
ServerName rt.mydomain.com
AddDefaultCharset UTF-8
DocumentRoot /opt/rt3/share/html

<Directory "/opt/rt3/share/html">
AuthName "Request Tracker"
AuthType NTLM
NTLMAuth on
NTLMAuthoritative on
NTLMDomain lhl.co.nz
NTLMServer dc1.mydomain.com
NTLMBackup dc2.mydomain.com
require valid-user
</Directory>
 

Directives in http.conf

This directives can be placed into a virtual directory to configure mod_ntlm:
NTLMAuth on/offenable/disable NTLM authentication
AuthNTGroups filenamerestrict access by looking up users in plain text group files (see below)
NTLMAuthoritative on/offallow users who couldn't be authenticated to be handled by other authentication modules
NTLMDomain domain_nameDomain users should be authenticated against
NTLMServer server_name or ip_addrPrimary SMB server to authenticate users (Windows NT or Samba)
NTLMBackup server_name or ip_addrBackup SMB server to authenticate users if primary is down
NTLMBasicAuth on/offenable/disable Basic authentication in addition to NTLM authentication. Note that setting NTLMAuth to off disables the Basic authentication of this module too.
NTLMBasicRealm realmThe realm to pass to the client for Basic authentication.
Require valid-userEvery user that is accepted by the SMB server can access this resource
Require user user_nameOnly this specific user(s) are allowed. Specify one or multiple users separated by spaces