首页 > 解决方案 > 密码保护目录不提示

问题描述

我正在运行一个只有 FTP 访问权限的 Windows NT 服务器。我正在尝试使用 .htaccess / .htpasswd 对目录进行密码保护,但无论是否安装了它,我仍然可以在没有提示的情况下访问目录中的页面。

我的 .htaccess 看起来像这样。

ErrorDocument 401 /401.html
AuthType Basic
AuthName "Password Required"
# path has been blocked out
AuthUserFile \hshome\xxx\xxx\xxx/.htpasswd
Options +FollowSymLinks
Order Deny,Allow
Satisfy any
Deny from All
Require valid-user
Allow from env=allow

什么会导致这种情况发生?

标签: apache.htaccess

解决方案


推荐阅读