【问题标题】:Authentication required for the folder [closed]文件夹需要身份验证[关闭]
【发布时间】:2012-03-19 01:11:19
【问题描述】:

我正在尝试访问 Linux Apache 服务器中的一个文件夹,但它会出现 Authenticatio Required 提示。

如何在 Cent OS VPS 服务器中重置或查找此登录详细信息?

这是通过 htpasswd 生成的吗?如果是,创建的文件的名称是什么?我在哪里可以找到它?

【问题讨论】:

    标签: linux apache mod-rewrite


    【解决方案1】:

    查看可能位于 /etc/httpd/ 文件夹中的 Apache 配置文件并查找类似这样的行块(可能在 VirtualHost 块中):

    AuthType Basic
    AuthName "Protected Files"
    AuthUserFile /etc/httpd/passwd/passwords
    Require user joe
    

    然后AuthUserFile 行将告诉您需要编辑的文件在哪里,以通过 htpasswd 命令添加/删除/更新用户,即更新“joe”密码

    htpasswd /etc/httpd/passwd/passwords joe 
    

    【讨论】:

      猜你喜欢
      • 2012-12-21
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2021-10-10
      • 1970-01-01
      • 2014-06-18
      • 2020-10-16
      • 1970-01-01
      相关资源
      最近更新 更多