[prev in list] [next in list] [prev in thread] [next in thread] 

List:       apache-httpd-users
Subject:    [users@httpd] files directive inside a directory directive
From:       oximoron <oximoron () alinto ! com>
Date:       2011-11-30 18:38:01
Message-ID: 4ED67809.8040700 () alinto ! com
[Download RAW message or body]

Hello,

I use the <Files> directive in order to ask a Ldap authentication on a 
file.

If I use the .htaccess file for that authentication, it works perfectly.
If I put the <Files> directive inside the <directory> directive in my 
apache conf (/etc/apache2/sites-enabled/https), when I go on my webpage, 
I have a:

"Authorization Required
This server could not verify that you are authorized to access the 
document requested. Either you supplied the wrong credentials (e.g., bad 
password), or your browser doesn't understand how to supply the 
credentials required."

But no popup shows up in order to ask me those credentials.

In FF, if I push F5, nothing changes.
In Iron (chrome like browser), if I push the F5 key, the popup shows up, 
I can give my credentials and it then works well.

Here is my conf:

Alias /jyraphe /var/www/jyraphe/pub
<Directory /var/www/jyraphe/pub>
         AllowOverride None
         Order deny,allow
         php_admin_value open_basedir 
/var/www/jyraphe/pub/:/var/www/jyraphe/documents/var/:/usr/share/php/:/tmp/

         Allow from 192.168.1.0/24

         SSLRequire %{SSL_CIPHER_USEKEYSIZE} >= 128

<Files index.php>
              AuthLDAPURL 
ldap://localhost/ou=Users,dc=xxx,dc=yyy?uid?sub?(objectClass=*)
              AuthType Basic
              AuthName "'Serveur XXX'"
              AuthBasicAuthoritative Off
              AuthBasicProvider ldap

              require valid-user
</Files>
</Directory>

I strangely, found nothing on the web about such a problem.
I must not have find the right words to search with, I guess..

Where can the problem come from?

Thanks
Kenny

[Attachment #3 (text/html)]

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>

<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
</head>
<body text="#000000" bgcolor="#ffffff">
Hello,
<br>
<br>
I use the &lt;Files&gt; directive in order to ask a Ldap authentication
on a file.
<br>
<br>
If I use the .htaccess file for that authentication, it works
perfectly.
<br>
If I put the &lt;Files&gt; directive inside the &lt;directory&gt;
directive in my apache conf (/etc/apache2/sites-enabled/https), when I
go on my webpage, I have a:
<br>
<br>
"Authorization Required
<br>
This server could not verify that you are authorized to access the
document requested. Either you supplied the wrong credentials (e.g.,
bad password), or your browser doesn't understand how to supply the
credentials required."
<br>
<br>
But no popup shows up in order to ask me those credentials.
<br>
<br>
In FF, if I push F5, nothing changes.
<br>
In Iron (chrome like browser), if I push the F5 key, the popup shows
up, I can give my credentials and it then works well.
<br>
<br>
Here is my conf:
<br>
<br>
Alias /jyraphe /var/www/jyraphe/pub
<br>
&lt;Directory /var/www/jyraphe/pub&gt;
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AllowOverride None
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Order deny,allow
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; php_admin_value open_basedir <i \
class="moz-txt-slash"><span  class="moz-txt-tag">/</span>var/www/jyraphe/pub<span
 class="moz-txt-tag">/</span></i>:<i class="moz-txt-slash"><span
 class="moz-txt-tag">/</span>var/www/jyraphe/documents/var<span
 class="moz-txt-tag">/</span></i>:<i class="moz-txt-slash"><span
 class="moz-txt-tag">/</span>usr/share/php<span class="moz-txt-tag">/</span></i>:<i
 class="moz-txt-slash"><span class="moz-txt-tag">/</span>tmp<span
 class="moz-txt-tag">/</span></i>
<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Allow from 192.168.1.0/24
<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SSLRequire %{SSL_CIPHER_USEKEYSIZE} &gt;= \
128 <br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;Files index.php&gt;
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AuthLDAPURL \
<a class="moz-txt-link-freetext">ldap://localhost/ou=Users,dc=xxx,dc=yyy?uid?sub?(objectClass=*)</a>
 <br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AuthType \
Basic <br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AuthName \
"'Serveur XXX'" <br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; \
AuthBasicAuthoritative Off <br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; \
AuthBasicProvider ldap <br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; require \
valid-user <br>
&nbsp; &nbsp;&nbsp; &nbsp; &lt;/Files&gt;
<br>
&lt;/Directory&gt;
<br>
<br>
I strangely, found nothing on the web about such a problem.
<br>
I must not have find the right words to search with, I guess..
<br>
<br>
Where can the problem come from?
<br>
<br>
Thanks
<br>
Kenny
</body>
</html>



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic