1

When I put

Order deny,allow
Deny from all
Allow from dev.example.com

into /etc/apache2/conf.d/restrict.conf, upon service apache2 restart I get

Syntax error on line 1 of /etc/apache2/conf.d/restrict.conf:
order not allowed here
Action 'configtest' failed.
The Apache error log may have more information.
   ...fail!

Please help.

1 Answer 1

2

Your problem is not that mod_authnz_host isn't installed or loaded, but that you put these directives in the wrong place. They are only valid in <Location ...> or <Directory ...> blocks like this:

<Location />
    Order deny,allow
    Deny from all
    Allow from dev.example.com
</Location>
1

You must log in to answer this question.