Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3843130
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T15:53:38+00:00 2026-05-19T15:53:38+00:00

In Apache, what would be the best way to only give access to users

  • 0

In Apache, what would be the best way to only give access to users who pass the two following tests:

  1. User does not appear in blacklist (alternatively, appears in whitelist)
  2. User has valid LDAP user account

I already have the second test in place but I now need to bar some of the valid LDAP users. Note that I cannot create an AD group to represent my black/white list.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-19T15:53:38+00:00Added an answer on May 19, 2026 at 3:53 pm

    I have managed to do that using

    • mod_auth_ldap to authenticate valid users
    • mod_authz_host to blacklist IP ranges

    The config then looks something like:

        <Location /blacklisted >
            AuthType Basic
            AuthName "PAM"
    
            AuthBasicProvider ldap
            Require valid-user
            AuthLDAPURL ldap://ldap.example.com/?sAMAccountName?sub
            AuthzLDAPAuthoritative off
            AuthLDAPBindDN bindUser@example.com
            AuthLDAPBindPassword verySecurePasswd
    
            Order allow,deny
            Deny from 192.168.1
            Allow from all
        </Location>
    

    However, I still don’t know whether that would be feasible if I wanted to blacklist LDAP usernames instead of IP addresses. (Covener seems to suggest some complex config could do it but I haven’t tried it).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I would like to enable SOAP on my PHP5/Centos/Apache server. I have full access
I'm trying to work out the best way to setup our multi-module Apache Maven
I'm running an Apache web server and was wondering what's the best way to
I would like to find an API like Apache Commons that will easily and
I would like to use mod_rewrite() on my apache setup on a windows machine.
I would like to implement a distinct thread for each route in apache camel.I
I would like to know the difference and additional features in Antennahouse over Apache
I have a small problem with url rewriting on apache. I would like it
Apache on a windows machine running as SYSTEM. What user and password should be
I am running an Apache server with PHP. Until now, emails to users have

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.