<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://coolscript.net/index.php?action=history&amp;feed=atom&amp;title=Apache_and_Ldap</id>
	<title>Apache and Ldap - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://coolscript.net/index.php?action=history&amp;feed=atom&amp;title=Apache_and_Ldap"/>
	<link rel="alternate" type="text/html" href="https://coolscript.net/index.php?title=Apache_and_Ldap&amp;action=history"/>
	<updated>2026-06-02T18:21:02Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.40.1</generator>
	<entry>
		<id>https://coolscript.net/index.php?title=Apache_and_Ldap&amp;diff=595&amp;oldid=prev</id>
		<title>Admin at 15:30, 10 December 2021</title>
		<link rel="alternate" type="text/html" href="https://coolscript.net/index.php?title=Apache_and_Ldap&amp;diff=595&amp;oldid=prev"/>
		<updated>2021-12-10T15:30:26Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 15:30, 10 December 2021&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l92&quot;&gt;Line 92:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 92:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthBasicProvider ldap&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthBasicProvider ldap&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   #AuthzLDAPAuthoritative Off&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   #AuthzLDAPAuthoritative Off&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthLDAPURL &quot;ldap://pdc.domain.com/ou=External,dc=&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;hitchhiker&lt;/del&gt;,dc=com?sAMAccountName?sub?&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthLDAPURL &quot;ldap://pdc.domain.com/ou=External,dc=&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;domain&lt;/ins&gt;,dc=com?sAMAccountName?sub?&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthLDAPBindDN &amp;quot;apache-ldap@domain.com&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthLDAPBindDN &amp;quot;apache-ldap@domain.com&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthLDAPBindPassword xxxxx&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthLDAPBindPassword xxxxx&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://coolscript.net/index.php?title=Apache_and_Ldap&amp;diff=593&amp;oldid=prev</id>
		<title>Admin at 15:29, 10 December 2021</title>
		<link rel="alternate" type="text/html" href="https://coolscript.net/index.php?title=Apache_and_Ldap&amp;diff=593&amp;oldid=prev"/>
		<updated>2021-12-10T15:29:20Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;a href=&quot;https://coolscript.net/index.php?title=Apache_and_Ldap&amp;amp;diff=593&amp;amp;oldid=344&quot;&gt;Show changes&lt;/a&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://coolscript.net/index.php?title=Apache_and_Ldap&amp;diff=344&amp;oldid=prev</id>
		<title>Admin at 14:28, 15 March 2021</title>
		<link rel="alternate" type="text/html" href="https://coolscript.net/index.php?title=Apache_and_Ldap&amp;diff=344&amp;oldid=prev"/>
		<updated>2021-03-15T14:28:08Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 14:28, 15 March 2021&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l204&quot;&gt;Line 204:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 204:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthLDAPURL &amp;quot;ldap://hh-intpdc.hitchhiker.com/cn=Users,dc=hitchhiker,dc=com?sAMAccountName?sub?(objectClass=*)&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthLDAPURL &amp;quot;ldap://hh-intpdc.hitchhiker.com/cn=Users,dc=hitchhiker,dc=com?sAMAccountName?sub?(objectClass=*)&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthLDAPBindDN &amp;quot;apache-ldap@hitchhiker.com&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthLDAPBindDN &amp;quot;apache-ldap@hitchhiker.com&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthLDAPBindPassword &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;0uru4w8v&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthLDAPBindPassword &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;xxxx&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   Require ldap-group cn=MYGROUP,cn=Users,dc=hitchhiker,dc=com&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   Require ldap-group cn=MYGROUP,cn=Users,dc=hitchhiker,dc=com&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  &amp;lt;/Files&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  &amp;lt;/Files&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l224&quot;&gt;Line 224:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 224:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthLDAPURL &amp;quot;ldap://hh-intpdc.hitchhiker.com/cn=Users,dc=hitchhiker,dc=com?sAMAccountName?sub?(objectClass=*)&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthLDAPURL &amp;quot;ldap://hh-intpdc.hitchhiker.com/cn=Users,dc=hitchhiker,dc=com?sAMAccountName?sub?(objectClass=*)&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthLDAPBindDN &amp;quot;apache-ldap@hitchhiker.com&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthLDAPBindDN &amp;quot;apache-ldap@hitchhiker.com&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthLDAPBindPassword &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;0uru4w8v&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   AuthLDAPBindPassword &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;xxxx&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   Require ldap-group cn=MYGROUP,cn=Users,dc=hitchhiker,dc=com&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   Require ldap-group cn=MYGROUP,cn=Users,dc=hitchhiker,dc=com&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  &amp;lt;/Directory&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  &amp;lt;/Directory&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://coolscript.net/index.php?title=Apache_and_Ldap&amp;diff=251&amp;oldid=prev</id>
		<title>Admin: Created page with &quot;=Apache and LDAP= This is how to get users authenticated against LDAP on AD. We&#039;re using: *Apache 2.2.16 *Debian 6 *AD on Server2012  First step is to create a user called &#039;&#039;&#039;...&quot;</title>
		<link rel="alternate" type="text/html" href="https://coolscript.net/index.php?title=Apache_and_Ldap&amp;diff=251&amp;oldid=prev"/>
		<updated>2021-01-13T14:37:08Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;=Apache and LDAP= This is how to get users authenticated against LDAP on AD. We&amp;#039;re using: *Apache 2.2.16 *Debian 6 *AD on Server2012  First step is to create a user called &amp;#039;&amp;#039;&amp;#039;...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;=Apache and LDAP=&lt;br /&gt;
This is how to get users authenticated against LDAP on AD.&lt;br /&gt;
We&amp;#039;re using:&lt;br /&gt;
*Apache 2.2.16&lt;br /&gt;
*Debian 6&lt;br /&gt;
*AD on Server2012&lt;br /&gt;
&lt;br /&gt;
First step is to create a user called &amp;#039;&amp;#039;&amp;#039;apache-ldap&amp;#039;&amp;#039;&amp;#039;, the user does not need to have any special permissions, it&amp;#039;s&lt;br /&gt;
just to read from LDAP.&lt;br /&gt;
&lt;br /&gt;
*Install the user tools:&lt;br /&gt;
 apt-get install ldap-utils&lt;br /&gt;
&lt;br /&gt;
*Enable autnz on apache (Already installed with 2.2)&lt;br /&gt;
 a2dismod authnz_ldap&lt;br /&gt;
 a2enmod authnz_ldap&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Set some defaults in /etc/ldap/ldap.conf&lt;br /&gt;
 BASE    dc=hitchhiker,dc=com&lt;br /&gt;
 REFERRALS off&lt;br /&gt;
&lt;br /&gt;
*Switch on debugging log in apache.conf&lt;br /&gt;
 LogLevel debug&lt;br /&gt;
&lt;br /&gt;
=Query LDAP=&lt;br /&gt;
*Basic Query&lt;br /&gt;
 ldapsearch -LLL  -H ldap://hh-intpdc.hitchhiker.com -x  -D &amp;#039;apache-ldap&amp;#039; -w &amp;#039;xxxxx&amp;#039;&lt;br /&gt;
&lt;br /&gt;
*Full query with no size limits, usefull to pipe the entire catalog to file&lt;br /&gt;
 ldapsearch -LLL  -E pr=1000/noprompt -x -H ldap://hh-intpdc.hitchhiker.com -x  -D &amp;#039;apache-ldap&amp;#039; -w &amp;#039;******&amp;#039;&lt;br /&gt;
&lt;br /&gt;
*Sample query to show all users, NOTE THAT AD does not know the OU=Users so we have to use the common name CN=Users&lt;br /&gt;
 ldapsearch -D &amp;quot;apache-ldap&amp;quot; -w xxxxxxxx -H ldap://hh-intpdc.hitchhiker.com -b &amp;quot;CN=Users,DC=hitchhiker,DC=com&amp;quot; &lt;br /&gt;
&lt;br /&gt;
*Sample query to show all user group called Male&lt;br /&gt;
 ldapsearch -D &amp;quot;apache-ldap&amp;quot; -w xxxxx -H ldap://hh-intpdc.hitchhiker.com -b &amp;quot;CN=Male,CN=Users,DC=hitchhiker,DC=com&amp;quot; objectclass=*&lt;br /&gt;
&lt;br /&gt;
=HTACCESS=&lt;br /&gt;
*sample of .htaccess&lt;br /&gt;
&lt;br /&gt;
 AuthName &amp;quot;Top Secret Area&amp;quot;&lt;br /&gt;
 AuthType Basic&lt;br /&gt;
 AuthBasicProvider ldap&lt;br /&gt;
 AuthzLDAPAuthoritative Off&lt;br /&gt;
 AuthLDAPURL &amp;quot;ldap://CENTAURI.hitchhiker.com/cn=Users,dc=hitchhiker,dc=com?sAMAccountName?sub?&lt;br /&gt;
 AuthLDAPBindDN &amp;quot;apache-ldap@hitchhiker.com&amp;quot;&lt;br /&gt;
 AuthLDAPBindPassword ****&lt;br /&gt;
&lt;br /&gt;
*Filter criterias, pick one or more&lt;br /&gt;
 #Filter for one or more usernames&lt;br /&gt;
 Require ldap-user &amp;quot;Username&amp;quot;&lt;br /&gt;
&lt;br /&gt;
 #Filter for existing mobile phone number and the department must be IT&lt;br /&gt;
 Require ldap-filter &amp;amp;(mobile=*)(department=IT)&lt;br /&gt;
&lt;br /&gt;
 #Filter for Exchange attributes&lt;br /&gt;
 Require ldap-attribute extensionAttribute3=GroupPolicy-ITAdmin&lt;br /&gt;
&lt;br /&gt;
 #Assumming a user calles stats within the group bookingstats at OU=IT&lt;br /&gt;
 Require ldap-group CN=bookingstats,ou=IT,dc=hitchhiker,dc=com&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Links&lt;br /&gt;
See: http://stackoverflow.com/questions/1405011/ldap-directory-entry-in-net-not-working-with-ou-users&amp;lt;br&amp;gt;&lt;br /&gt;
https://www.sit.auckland.ac.nz/LDAP_authentication_with_Apache_mod_authnz_ldap&amp;lt;br&amp;gt;&lt;br /&gt;
http://www.held-im-ruhestand.de/software/apache-ldap-active-directory-authentication&amp;lt;br&amp;gt;&lt;br /&gt;
http://www.conigliaro.org/2008/12/31/active-directory-authentication-on-apache-with-mod_authnz_ldap/&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=Setup sample of statistics=&lt;br /&gt;
bookingstats.intern and statistics.hitchhiker.net are different server in different networks, they use both different sql servers (security) but&lt;br /&gt;
use the same ldap server to authenticate.&amp;lt;br&amp;gt;&lt;br /&gt;
The goal of this is having both, STATUSER and External user logging in to both server.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:bookingstats.png]]&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
==Setup external OU==&lt;br /&gt;
Create an OU called &amp;#039;&amp;#039;&amp;#039;External&amp;#039;&amp;#039;&amp;#039;. Add a group called &amp;#039;&amp;#039;&amp;#039;statistics&amp;#039;&amp;#039;&amp;#039; and add the external users into this group:&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:ads-ldap01.png]]&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Setup the internal Exchange Attribute==&lt;br /&gt;
Edit the exchange attribute number 4 and type &amp;#039;&amp;#039;&amp;#039;STATUSER&amp;#039;&amp;#039;&amp;#039;:&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:ads-ldap02.png]]&lt;br /&gt;
&lt;br /&gt;
=Apache config sample for bookingstats.intern=&lt;br /&gt;
We use the Exchange attributes as main authentication and the external OU &amp;#039;&amp;#039;&amp;#039;External&amp;#039;&amp;#039;&amp;#039; as second authentication.&lt;br /&gt;
This is named like &amp;#039;&amp;#039;&amp;#039;Apache authentication from multiple domains in AD with mod_authn_alias&amp;#039;&amp;#039;&amp;#039;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*/etc/apache2/sites-available/bookingstats&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;AuthnProviderAlias ldap first-ldap&amp;gt;&lt;br /&gt;
  AuthBasicProvider ldap&lt;br /&gt;
  AuthLDAPURL &amp;quot;ldap://CENTAURI.hitchhiker.com/cn=Users,dc=hitchhiker,dc=com?sAMAccountName?sub?&lt;br /&gt;
  AuthLDAPBindDN &amp;quot;apache-ldap@hitchhiker.com&amp;quot;&lt;br /&gt;
  AuthLDAPBindPassword xxxxx&lt;br /&gt;
  &amp;#039;&amp;#039;&amp;#039;Require ldap-attribute extensionAttribute4=STATUSER&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
  AuthType Basic&lt;br /&gt;
  # Important, otherwise &amp;quot;(9)Bad file descriptor: Could not open password file: (null)&amp;quot;&lt;br /&gt;
  AuthUserFile /dev/null&lt;br /&gt;
 &amp;lt;/AuthnProviderAlias&amp;gt;&lt;br /&gt;
 &amp;lt;AuthnProviderAlias ldap second-ldap&amp;gt;&lt;br /&gt;
  AuthBasicProvider ldap&lt;br /&gt;
  #AuthzLDAPAuthoritative Off&lt;br /&gt;
  AuthLDAPURL &amp;quot;ldap://CENTAURI.hitchhiker.com/ou=External,dc=hitchhiker,dc=com?sAMAccountName?sub?&lt;br /&gt;
  AuthLDAPBindDN &amp;quot;apache-ldap@hitchhiker.com&amp;quot;&lt;br /&gt;
  AuthLDAPBindPassword xxxxx&lt;br /&gt;
  &amp;#039;&amp;#039;&amp;#039;Require ldap-group CN=statistics,ou=External,dc=hitchhiker,dc=com&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
 &amp;lt;/AuthnProviderAlias&amp;gt;&lt;br /&gt;
 &amp;lt;Directory &amp;quot;/usr/local/www/bookingstats/cgi-bin/&amp;quot;&amp;gt;&lt;br /&gt;
  Options IncludesNoExec&lt;br /&gt;
  Allow from 10.0.1 192.168&lt;br /&gt;
  Order allow,deny&lt;br /&gt;
  Allow from all&lt;br /&gt;
  AddHandler cgi-script .cgi .pl&lt;br /&gt;
  PerlResponseHandler ModPerl::Registry&lt;br /&gt;
  PerlOptions +ParseHeaders&lt;br /&gt;
  Options +ExecCGI&lt;br /&gt;
  AuthName &amp;quot;Use your Windows account&amp;quot;&lt;br /&gt;
  AuthType Basic&lt;br /&gt;
  &amp;#039;&amp;#039;&amp;#039;AuthBasicProvider first-ldap second-ldap&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
  AuthzLDAPAuthoritative off&lt;br /&gt;
  require valid-user&lt;br /&gt;
 &amp;lt;/Directory&amp;gt;&lt;br /&gt;
 &amp;lt;Virtualhost *:80&amp;gt;&lt;br /&gt;
  ServerAdmin mk@hitchhiker.com&lt;br /&gt;
  ServerName bookingstats.intern&lt;br /&gt;
  DocumentRoot /usr/local/www/bookingstats/cgi-bin/&lt;br /&gt;
  #Reroute to frame&lt;br /&gt;
  DirectoryIndex frame.pl /frame.pl&lt;br /&gt;
  ErrorLog /var/log/apache2/bookingstats.error&lt;br /&gt;
  LogLevel info&lt;br /&gt;
  CustomLog /var/log/apache2/bookingstats.access combined&lt;br /&gt;
  Redirect /index.html http://bookingstats.intern/cgi-bin/start.pl&lt;br /&gt;
 &amp;lt;/Virtualhost&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Apache config sample for statistics.hitchhiker.net=&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;AuthnProviderAlias ldap first-ldap&amp;gt;&lt;br /&gt;
  AuthBasicProvider ldap&lt;br /&gt;
  AuthLDAPURL &amp;quot;ldap://CENTAURI.hitchhiker.com/cn=Users,dc=hitchhiker,dc=com?sAMAccountName?sub?&lt;br /&gt;
  AuthLDAPBindDN &amp;quot;apache-ldap@hitchhiker.com&amp;quot;&lt;br /&gt;
  AuthLDAPBindPassword xxxx&lt;br /&gt;
  &amp;#039;&amp;#039;&amp;#039;Require ldap-attribute extensionAttribute4=STATUSER&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
  AuthType Basic&lt;br /&gt;
  # Important, otherwise &amp;quot;(9)Bad file descriptor: Could not open password file: (null)&amp;quot;&lt;br /&gt;
  AuthUserFile /dev/null&lt;br /&gt;
 &amp;lt;/AuthnProviderAlias&amp;gt;&lt;br /&gt;
 &amp;lt;AuthnProviderAlias ldap second-ldap&amp;gt;&lt;br /&gt;
  AuthBasicProvider ldap&lt;br /&gt;
  AuthLDAPURL &amp;quot;ldap://CENTAURI.hitchhiker.com/ou=External,dc=hitchhiker,dc=com?sAMAccountName?sub?&lt;br /&gt;
  AuthLDAPBindDN &amp;quot;apache-ldap@hitchhiker.com&amp;quot;&lt;br /&gt;
  AuthLDAPBindPassword xxxxx&lt;br /&gt;
  &amp;#039;&amp;#039;&amp;#039;Require ldap-group CN=statistics,ou=External,dc=hitchhiker,dc=com&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
 &amp;lt;/AuthnProviderAlias&amp;gt;&lt;br /&gt;
 &amp;lt;Directory &amp;quot;/ftpweb/web/statistics.hitchhiker.net/cgi-bin/&amp;quot;&amp;gt;&lt;br /&gt;
  Options ExecCGI&lt;br /&gt;
  DirectoryIndex frame.pl&lt;br /&gt;
  Options IncludesNoExec&lt;br /&gt;
  #AuthType Basic&lt;br /&gt;
  Order allow,deny&lt;br /&gt;
  Allow from all&lt;br /&gt;
  AddHandler cgi-script .cgi .pl&lt;br /&gt;
  PerlResponseHandler ModPerl::Registry&lt;br /&gt;
  PerlOptions +ParseHeaders&lt;br /&gt;
  Options +ExecCGI&lt;br /&gt;
  AuthName &amp;quot;Statistic Area&amp;quot;&lt;br /&gt;
  AuthType Basic&lt;br /&gt;
  &amp;#039;&amp;#039;&amp;#039;AuthBasicProvider second-ldap first-ldap&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
  AuthzLDAPAuthoritative off&lt;br /&gt;
  require valid-user&lt;br /&gt;
 &amp;lt;/Directory&amp;gt;&lt;br /&gt;
 &amp;lt;VirtualHost *:80&amp;gt;&lt;br /&gt;
  ServerName statistics.hitchhiker.net&lt;br /&gt;
  Redirect permanent / https:/statistics.hitchhiker.net/&lt;br /&gt;
 &amp;lt;/VirtualHost&amp;gt;&lt;br /&gt;
 &amp;lt;VirtualHost *:443&amp;gt;&lt;br /&gt;
  SSLCertificateFile /etc/apache2/ssl/statistics.hitchhiker.net.crt&lt;br /&gt;
  SSLCertificateKeyFile /etc/apache2/ssl/statistics.hitchhiker.net.key&lt;br /&gt;
  SSLEngine on&lt;br /&gt;
  ServerAdmin mis@hitchhiker.com&lt;br /&gt;
  ServerName statistics.hitchhiker.net&lt;br /&gt;
  DocumentRoot /ftpweb/web/statistics.hitchhiker.net/cgi-bin&lt;br /&gt;
  ErrorLog /var/log/apache2/statistics.hitchhiker.net.error&lt;br /&gt;
  CustomLog /var/log/apache2/statistics.hitchhiker.net.access combined&lt;br /&gt;
  DirectoryIndex frame.pl /frame.pl&lt;br /&gt;
  SSLHonorCipherOrder On&lt;br /&gt;
  SSLProtocol +ALL -SSLv3 -SSLv2&lt;br /&gt;
  SSLCipherSuite DHE-RSA-AES256-GCM-SHA384:DHE-RSA-AES256-SHA256:DHE-RSA-AES256-SHA:DHE-RSA-AES128-SHA:AES256-SHA:AES128-SHA&lt;br /&gt;
 &amp;lt;/VirtualHost&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Using AD Group within Directory, Location or File=&lt;br /&gt;
Sample to use the AD Group &amp;#039;&amp;#039;&amp;#039;MYGROUP&amp;#039;&amp;#039;&amp;#039;&amp;#039; within a Files context&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;Files &amp;quot;manage.pl&amp;quot;&amp;gt;&lt;br /&gt;
  AuthName &amp;quot;Use your winwods accoutn to login&amp;quot;&lt;br /&gt;
  AuthBasicProvider ldap&lt;br /&gt;
  AuthType Basic&lt;br /&gt;
  AuthLDAPGroupAttribute member&lt;br /&gt;
  AuthLDAPGroupAttributeIsDN On&lt;br /&gt;
  AuthLDAPURL &amp;quot;ldap://hh-intpdc.hitchhiker.com/cn=Users,dc=hitchhiker,dc=com?sAMAccountName?sub?(objectClass=*)&amp;quot;&lt;br /&gt;
  AuthLDAPBindDN &amp;quot;apache-ldap@hitchhiker.com&amp;quot;&lt;br /&gt;
  AuthLDAPBindPassword 0uru4w8v&lt;br /&gt;
  Require ldap-group cn=MYGROUP,cn=Users,dc=hitchhiker,dc=com&lt;br /&gt;
 &amp;lt;/Files&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Sample to use the AD Group &amp;#039;&amp;#039;&amp;#039;MYGROUP&amp;#039;&amp;#039;&amp;#039;&amp;#039; within a Directryy context&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;Directory &amp;quot;/usr/local/www/testcode.internxx&amp;quot;&amp;gt;&lt;br /&gt;
  Options Indexes MultiViews ExecCGI&lt;br /&gt;
  DirectoryIndex index.htm&lt;br /&gt;
  Order allow,deny&lt;br /&gt;
  Allow from all&lt;br /&gt;
  AddHandler cgi-script .cgi .pl .htm&lt;br /&gt;
  DirectoryIndex index.htm&lt;br /&gt;
  AuthName &amp;quot;Use your winwods accoutn to login&amp;quot;&lt;br /&gt;
  AuthBasicProvider ldap&lt;br /&gt;
  AuthType Basic&lt;br /&gt;
  AuthLDAPGroupAttribute member&lt;br /&gt;
  AuthLDAPGroupAttributeIsDN On&lt;br /&gt;
  AuthLDAPURL &amp;quot;ldap://hh-intpdc.hitchhiker.com/cn=Users,dc=hitchhiker,dc=com?sAMAccountName?sub?(objectClass=*)&amp;quot;&lt;br /&gt;
  AuthLDAPBindDN &amp;quot;apache-ldap@hitchhiker.com&amp;quot;&lt;br /&gt;
  AuthLDAPBindPassword 0uru4w8v&lt;br /&gt;
  Require ldap-group cn=MYGROUP,cn=Users,dc=hitchhiker,dc=com&lt;br /&gt;
 &amp;lt;/Directory&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Caching=&lt;br /&gt;
Caching is enabled by default, to see the stats add the following location:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;Location /server/cache-info&amp;gt;&lt;br /&gt;
  SetHandler ldap-status&lt;br /&gt;
 &amp;lt;/Location&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Disable caching in eg apache.conf&lt;br /&gt;
 LDAPOpCacheEntries 0&lt;br /&gt;
&lt;br /&gt;
See: https://httpd.apache.org/docs/2.4/mod/mod_ldap.html&lt;br /&gt;
&lt;br /&gt;
=Links:=&lt;br /&gt;
http://serverfault.com/questions/312281/apache-authentication-from-multiple-domains-in-ad-with-mod-authn-alias\&amp;lt;br&amp;gt;&lt;br /&gt;
http://serverfault.com/questions/140858/authenticating-apache-httpd-against-multiple-ldap-servers-with-expired-accounts&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Resources=&lt;br /&gt;
*[[Bookingstats.intern]]&lt;br /&gt;
*[[Bookingstats]]&lt;br /&gt;
&amp;lt;br&amp;gt;Keywords: bookingstats stats statistics statistics.hitchhiker.net bookingstats.intern ldap&lt;br /&gt;
&lt;br /&gt;
Keywords: bookingstats stats statistics&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
</feed>