【问题标题】:Apache Log says: Deny - but it works (htaccess)Apache Log 说:拒绝 - 但它有效(htaccess)
【发布时间】:2012-05-18 22:50:12
【问题描述】:

我正在玩一点 htaccess 来了解 apache 和 xampp。

我为整个/目录配置了“AllowOverride All”,文件夹中的.htaccess文件正常工作。

我被排除在“私人”文件夹之外,我可以访问“公共”文件夹。但是日志说的完全不同。

例如基本认证.htaccess:

# .htaccess for password
AuthType Basic
AuthName "password Folder is for password Folders"
AuthUserFile C:/xampp/htdocs/password/.htusers
Require valid-user

我可以使用正确的密码登录。但是日志说它被拒绝了!?

Apache 错误日志:

[2012 年 5 月 10 日星期四 13:04:05] [错误] [客户端 ::1] 客户端被拒绝 服务器配置:C:/xampp/htdocs/password/.htaccess [5 月 10 日星期四 2012 年 13:04:05] [错误] [客户端 ::1] 客户端被服务器拒绝 配置:C:/xampp/htdocs/password/.htusers

为什么?正如我所见,它可以工作 - 但为什么日志告诉我一些完全不同的东西?

【问题讨论】:

    标签: apache .htaccess


    【解决方案1】:

    问题的解决方案,也可能是 apache 或 xampp 中的日志错误(我不知道),是将文件放入目录中。如果发生这种情况,错误消息就会消失。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2013-02-17
      • 2010-11-20
      • 1970-01-01
      • 1970-01-01
      • 2016-01-31
      • 2014-03-25
      • 2012-01-30
      • 2012-03-19
      相关资源
      最近更新 更多