AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / user-214128

raphael75's questions

Martin Hope
raphael75
Asked: 2024-05-03 22:05:02 +0800 CST

尝试在 apache 中的别名目录上配置密码保护

  • 5

我的 Windows 服务器上有 apache 2.4.57。我新建了一个文件夹,只需要显示可以下载的文件。在 httpd.conf 文件中,我添加了以下内容:

Alias "/pw_files" "f:\www_shared\pw_files" 
<Directory "f:\www_shared\pw_files">
    Require all granted
    Options Indexes
    IndexOptions FancyIndexing HTMLTable FoldersFirst SuppressDescription SuppressLastModified NameWidth=* IconWidth=20 IconHeight=20
    IndexStyleSheet /css/autoindex.css
</Directory>

我在 f:\www_shared\pw_files 中创建了一个 .htpasswd 文件:

AuthType Basic
AuthName "please enter credentials"
AuthUserFile f:\www_shared\pw_files
AuthGroupFile "c:/apache_php/apache/htpasswd_group2.txt"
Require group pw_files

我创建了一个新用户:

htpasswd -c f:\www_shared\pw_files\.htpasswd pw_user

我将输出从 .htpasswd 移至 c:\apache_php\apache 中的 .htpasswd 文件

在 c:/apache_php/apache/htpasswd_group2.txt 我有:

pw_files: admin pw_user

我进行了这些更改并重新启动。

但是,当我去:

http://www.example.com/pw_files

我需要查看该文件夹的内容,但我从未收到输入用户名和密码的提示。我不确定我错过了什么。

apache-2.4
  • 1 个回答
  • 23 Views
Martin Hope
raphael75
Asked: 2018-06-20 06:00:31 +0800 CST

cygwin可以在启动时运行吗

  • 0

在普通的 Linux 中,我可以将东西放在 rc.local 中以在启动时运行。有没有办法在 Cygwin 中做到这一点?似乎当我启动 Cygwin 终端时,它不会自动运行任何东西。

具体来说,我希望它启动 mysqld。

cygwin
  • 1 个回答
  • 169 Views

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    新安装后 postgres 的默认超级用户用户名/密码是什么?

    • 5 个回答
  • Marko Smith

    SFTP 使用什么端口?

    • 6 个回答
  • Marko Smith

    命令行列出 Windows Active Directory 组中的用户?

    • 9 个回答
  • Marko Smith

    什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同?

    • 3 个回答
  • Marko Smith

    如何确定bash变量是否为空?

    • 15 个回答
  • Martin Hope
    Tom Feiner 如何按大小对 du -h 输出进行排序 2009-02-26 05:42:42 +0800 CST
  • Martin Hope
    Noah Goodrich 什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同? 2009-05-19 18:24:42 +0800 CST
  • Martin Hope
    Brent 如何确定bash变量是否为空? 2009-05-13 09:54:48 +0800 CST
  • Martin Hope
    cletus 您如何找到在 Windows 中打开文件的进程? 2009-05-01 16:47:16 +0800 CST

热门标签

linux nginx windows networking ubuntu domain-name-system amazon-web-services active-directory apache-2.4 ssh

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve