I'm using Apache 2.2 instead of 2.4, which explains the error in the title. After Brain99 posted his comment, I found out that I had 2.2, adjusted my configuration to what he suggested (which still didn't work), tried around a bit, slept a night and the next day I found out, that I forgot the Include statements for the mod-enabled directory!
For now I just need the server to let me download files from one specific folder (in my case I chose /opt/myFolder for that task)
Distribution is Debian 6.0
edit_start
Apache version is 2.4, according to their official documentation, the Order/Allow clauses are deprecated and should not be used anymore
I'm an idiot: Apache version is 2.2.
edit_end
My directory directives in apache2.conf look like this:
<IfModule dir_module>
DirectoryIndex index.html index.htm index.php
</IfModule>
ServerRoot "/etc/apache2"
DocumentRoot "/opt/myFolder"
<Directory />
Options FollowSymLinks
AuthType None
AllowOverride None
Require all denie
</Directory>
<Directory "/opt/myFolder/*">
Options FollowSymLinks MultiViews
AllowOverride None
AuthType None
Require all allow
</Directory>
When I try to access a file inside that folder (http://myserver.de/aTestFile.zip) I get an Internal Server Error. Also Apache writes the following error into it's log:
configuration error: couldn't check user. Check your authn provider!: /aTestFile.zip
Why would I need an authn provider if I don't want any authentication? Also I hope someone can explain to me what kind of AuthenticationProvider I'd need for that. Everytime I search for those things I get pointed at people asking how to protect files/directories with passwords or restrict access to some IP addresses, which doesn't really help me.
ok, since I've Apache version 2.2, here is the error I get when using the Order/Deny/Allow commands instead of AuthType/Require:
Invalid command 'Order', perhaps misspelled or defined by a module not included in the server configuration.
I believe this is due to the following erroneous configuration directives:
Try the following configuration instead:
Edit 2: Your problem could also be due to the mod_authz_host module not being loaded. You can try enabling this with
a2enmod authz_host
and restarting apache.Also, it seems that
AuthType None
is invalid. Just remove theAuthType
directive entirely from your configuration.