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'm trying to work out the best way to setup our multi-module Apache Maven
Can you tell the BEST way how to test & use Web Services in
I have a pretty complicated index.php now, and I would like to only run
I want to use the org.apache.commons.exec Java library to call an executable. Does the
I have a seam app and would like to use the MultiPowUploader ( http://www.element-it.com/multiple-file-upload/flash-uploader.aspx
I would like to configure a DataSource using JNDI in a Java SE app.
I've got a webapp (basically a CMS) running on Apache built with PHP5/MySQL. Which
Apache version 2.2.11 (Unix) Architecture x86_64 Operating system Linux Kernel version 2.6.18-164.el5 Ok, here
I'm developing a website that will be available in different languages. It is a
This question is similar to the one i asked here . But its related

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.