Ok, lets say I have a normal text file on my server in the document root.
Suppose the folder on the system assigned to document root is /doc
.
The filename will be a.txt
(stored as /doc/a.txt
)
The folder is setup to allow Apache configuration from a .htaccess
file.
This is my main server httpd.conf
file relevant to the /doc
folder:
<Directory "/doc">
Options -Indexes +FollowSymLinks -multiviews
AllowOverride All
</Directory>
Assuming my public domain is http://www.example.com
, I request http://www.example.com/a.txt
to download the file.
I then look behind the scenes on the server side with strace
.
It looks normal when Apache wants to load /doc/.htaccess
(.htaccess
from the document root folder), but it's also trying to load /doc/a.txt/.htaccess
as well.
Why would Apache append .htaccess
to the entire resource and request it to exist on the server? And how do I disable only that scan for .htaccess
?
For clarity: searching for /doc/.htaccess
is fine, but searching for /doc/a.txt/.htaccess
is unacceptable.