Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
在 apache2 网络服务器上禁用目录浏览的最佳做法是什么?我想在 httpd.conf 禁用此功能会限制浏览,即使有人获得了对网络服务器上 .htaccess 文件的访问权限并启用了目录浏览?想法?
通过服务器配置更简单,但 htaccess 通常是唯一的方法。特别是在共享主机上。
如果有人操纵 htaccess 文件,您不需要保护您的文件。在那种情况下,已经为时已晚。