从我能读到的变化
Options All Indexes FollowSymLinks MultiViews
Run Code Online (Sandbox Code Playgroud)
到
Options All FollowSymLinks MultiViews
Run Code Online (Sandbox Code Playgroud)
inhttpd.conf应该禁用目录列表,但我仍然可以列出它们。
我只能使用.htaccess文件禁用此功能。
题
如何禁用httpd.confforDocumentRoot和 all 中VirtualHost的目录列表?
不,它不是那样工作的,这All意味着启用所有选项,除了MultiViews,顺序也很重要。要禁用目录列表,你需要-Indexes这样
Options All FollowSymLinks MultiViews -Indexes
Run Code Online (Sandbox Code Playgroud)
会工作,但
Options -Indexes All FollowSymLinks MultiViews
Run Code Online (Sandbox Code Playgroud)
不会因为All之后-Indexes会重新启用它。
| 归档时间: |
|
| 查看次数: |
12207 次 |
| 最近记录: |