0

I'm building an API which will only be accessible to local services by using Require local in the <Location> directive. How can I make this return a 404 rather than 403 status code when accessed from a remote address? That way I can hide the fact that there is a service at the requested location.

I'd rather preserve the semantics of Require local than use mod_rewrite.

1 Answer 1

0

Turns out this isn't too difficult:

ErrorDocument 403 /unauthorized_remote_access
Redirect 404 /unauthorized_remote_access

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .