Thank you, but that does not answer my question. My question is how to avoid sending out a 403 header and instead not to send back ANYTHING at all.
Main Topics
Browse All TopicsHello,
The following returns "403 Forbidden" unless you have the correct env.
Order Deny, Allow
Deny from all
Allow from env=let_me_in
I don't want a "403 Forbidden" -- instead I want "This Page Cannot Be Displayed" unless you have the correct env. The same error you would get if the server was offline. Can this be done from .htaccess or httpd.conf?
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
just to elaborate what has been mentioned by giltr:
The error code are very much the standard - http://www.w3.org/Protocol
403 Forbidden
404 Not Found
since in this case the client that does not had the env var "let-me-in" configured -- the server would throw a 403 error.
http://httpd.apache.org/do
a trick -- which I never tested :) is to "redefine" 403 -- to any of this option.
1. output a simple hardcoded error message
2. output a customized message
3. redirect to a local URL-path to handle the problem/error
4. redirect to an external URL to handle the problem/error
since you insist on 404 error to be returned, you could redifined to a resources that is not protected (by the access control that you defined earlier), and make sure that particular page does not exist. Thus, client may get a 404 (Not Found).
i hope this may work :)
cheers.
i had tried to catch 401 error, and redirect to a page that does not exist. however, the server still sends 401 error, together with a 404 (since the redirected page does not exist).
I am not sure if this satisfy you.
==quote from http://httpd.apache.org/do
ErrorDocument Directive
Description: What the server will return to the client in case of an error
Syntax: ErrorDocument error-code document
Context: server config, virtual host, directory, .htaccess
Override: FileInfo
Status: Core
Module: core
Compatibility: Quoting syntax for text messages is different in Apache 2.0
check this page out -- that may be possible : http://httpd.apache.org/do
basically, just catch the 403 error using ErrorDocument and redirect it to a cgi script that throw a 404 response to the client.
give it a shot.
Business Accounts
Answer for Membership
by: giltjrPosted on 2007-10-07 at 16:48:45ID: 20031380
Possibily. IE allows you to configure it for friendly messages. If IE is configured for friendly messages, then it will ignore any custom error message you create.
torials/mi sc/errors. php itemanager /apache/er rors-403.s html
You can visit:
http://www.4webhelp.net/tu
http://www.codestyle.org/s
or any other site you find searching for custom apache errors
The basic is that you add:
ErrorDocument 403 /error-docs/403.html
in your .htaccess file. Then you create your custom error page in that file in that directory. The path can be anyplace you want.