You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Matt Zagrabelny <mz...@d.umn.edu> on 2007/06/11 18:42:20 UTC

[users@httpd] authentication for proxy_balancer

Hello,

I have question regarding using apache2.2 to provide
authentication/authorization to content being served via proxy_balancer.

However, I am trying to get the things working in a simpler environment
with a single proxy and an authentication statement for it.

url: https://grateful.d.umn.edu/ajaxterm/

here is the relavent section of the config file:

ProxyRequests Off
<Location /proxy/>
  ProxyPass http://localhost:12201/
  ProxyPassReverse http://localhost:12201/
  Order deny,allow
  AuthBasicProvider ldap
  AuthLDAPURL <removed>
  AuthLDAPBindDN <removed>
  AuthLDAPBindPassword <removed>
  AuthzLDAPAuthoritative off
  AuthUserFile /var/www/.htaccess
</Location>

I have tried many different configurations and cannot seem to get the
Authentication to take. Note, the same Authentication seems to work for
a plain directory:

url: https://grateful.d.umn.edu/auth/

<Directory /var/www/auth/>
  Order deny,allow
  AuthBasicProvider ldap
  AuthLDAPURL <removed>
  AuthLDAPBindDN <removed>
  AuthLDAPBindPassword <removed>
  AuthzLDAPAuthoritative off
  AuthUserFile /var/www/.htaccess
</Directory>

There does not seem to be any indication of failure in the log files
(access.log and error.log).

Any suggestions?

-- 
Matt Zagrabelny - mzagrabe@d.umn.edu - (218) 726 8844
University of Minnesota Duluth
Information Technology Systems & Services
PGP key 1024D/84E22DA2 2005-11-07
Fingerprint: 78F9 18B3 EF58 56F5 FC85  C5CA 53E7 887F 84E2 2DA2

He is not a fool who gives up what he cannot keep to gain what he cannot
lose.
-Jim Elliot

Re: [users@httpd] authentication for proxy_balancer - SOLVED

Posted by Matt Zagrabelny <mz...@d.umn.edu>.
One major problem in my understanding of the apache configs was using
the wrong directive. Well, actually, someone told me to use a directive
that wasn't the appropriate directive to use. That is, the AuthUserFile
directive. AuthUserFile as you all know, and now I do too, is used as an
authentication file of username - password pairs, one per line; not a
place to include commands you'd find in an htaccess file.

Thus I changed "AuthUserFile" to "Include" and it works. Here is the
relevant sections of the config files:

/var/www/.htaccess
AuthType Basic
AuthName "LDAP Required"
Require user matt

/etc/apache2/conf.d/prox.conf
<Location /proxy/>
  ProxyPass http://localhost:12201/
  ProxyPassReverse http://localhost:12201/
  Order deny,allow
  AuthBasicProvider ldap
  AuthLDAPURL  <removed>
  AuthLDAPBindDN <removed>
  AuthLDAPBindPassword <removed>
  AuthzLDAPAuthoritative off
  Include /var/www/.htaccess
</Location>


> ProxyRequests Off
> <Location /proxy/>
>   ProxyPass http://localhost:12201/
>   ProxyPassReverse http://localhost:12201/
>   Order deny,allow
>   AuthBasicProvider ldap
>   AuthLDAPURL <removed>
>   AuthLDAPBindDN <removed>
>   AuthLDAPBindPassword <removed>
>   AuthzLDAPAuthoritative off
>   AuthUserFile /var/www/.htaccess
> </Location>

-- 
Matt Zagrabelny - mzagrabe@d.umn.edu - (218) 726 8844
University of Minnesota Duluth
Information Technology Systems & Services
PGP key 1024D/84E22DA2 2005-11-07
Fingerprint: 78F9 18B3 EF58 56F5 FC85  C5CA 53E7 887F 84E2 2DA2

He is not a fool who gives up what he cannot keep to gain what he cannot
lose.
-Jim Elliot