Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am working on a project of setting up a web administered inventory database for my work (or if they don't want it then i'll enjoy learning about it) and hit the problem of allowing only authorized users to access the website (In its testing/development phase, I allow all people to navigate to the website to add entries to the database and query it). I am trying to make it so only particular users in the domain (Active Directory) are allowed to access the website after they are queried about their credentials. I read that Apache (I am using a LAMP server) has a means of asking visitors to the website to provide LDAP credentials in order to gain access to the site, but I wasn't sure if that was exactly what I was looking for. If anyone has experience in the LDAP configurations for Apache that I mentioned or any other means of securely authenticating with websites I would greatly appreciate advice or a direction to go

Thank you!

share|improve this question
@RedGrittyBrick Didn't know I had to review answers. Thanks for the heads up – Stephen R May 9 '12 at 16:48
why don't you use php (or your language of choice) to connect and authenticate through LDAP. You can see how it is done in media wiki for example. – jet Mar 19 '13 at 0:01

apache has a module - mod_authnz_ldap for ldap authentication.

There are many how-to's describing how to implement it.

Docs for the module:

share|improve this answer
When a user makes a connection to the web server that Apache is on (provided that the LDAP module you mentioned is being used), will the user be asked for their credentials before they are allowed to continue to the website? If that is the case then I will certainly pursue using the modules. – Stephen R May 9 '12 at 17:00

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.