linux – 如何禁用目录列表?

从我可以阅读的变化
Options All Indexes FollowSymLinks MultiViews

Options All FollowSymLinks MultiViews

在httpd.conf中应该禁用目录列表,但我仍然可以列出它们.

我只能使用.htaccess文件禁用它.

如何在httpd.conf中禁用DocumentRoot和所有VirtualHost的目录列表?

解决方法

不,它不起作用,All表示启用除MultiViews之外的所有选项,顺序也很重要.要禁用目录列表,您需要-Indexes
Options All FollowSymLinks MultiViews -Indexes

会工作但是

Options -Indexes All FollowSymLinks MultiViews

不会像-Index之后的All那样重新启用它.

相关文章

1、安装Apache。 1)执行如下命令,安装Apache服务及其扩展包...
一、先说一下用ansible批量采集机器信息的实现办法: 1、先把...
安装配置 1. 安装vsftpd 检查是否安装了vsftpd # rpm -qa | ...
如何抑制stable_secret读取关键的“net.ipv6.conf.all.stabl...
1 删除0字节文件 find -type f -size 0 -exec rm -rf {} ...
## 步骤 1:安装必要的软件包 首先,需要确保系统已安装 `dh...