[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[no subject]



ErrorDocument 500 "The server made a boo boo.
ErrorDocument 404 http://192.168.1.1/error.htm
ErrorDocument 403 "Access Forbidden -- Go away.

Check these sites out:
http://penguin.epfl.ch/httpd.conf.html
http://www.linuxdoc.org/LDP/solrhe/Securing-Optimizing-Linux-RH-Edition-v1.3
/chap29sec245.html

Now what confuses me on what I read on the list and what I am seeing
is some people say put it at the end of the </VirtualHost>...
some say it you have to add it to every virtual host and from what
I am seeing I am a little confused.

I can't get mine to work with .httaccess but I would like to edit the
httpd.config and setup a default like above and have it /404.html, /401.html
so when people want to have custom pages done they just have to create
their own and place it in the "Document Site /web" directory of their site.

One I have seen:
<VirtualHost www.domain.org domain.org>
ServerName www.servername.org
ServerAdmin uzzzzzs@xxxxxxxxxxxx
DocumentRoot /usr/local/etc/httpd/vhosts/etc
TransferLog logs/etc_access
ScriptAlias /cgi-bin/ /usr/local/etc/httpd/htdocs/zzzzetc/cgi-bin/
ErrorDocument 404 /errors/notfound.html  <----- This is it right here...
</VirtualHost>

I don't feel like going through 30 sites and adding 4 lines of code...
the 404, 500, 401, 403 and so on...

I might be wrong, make sure you backup your httpd.conf before you start
changing things
and you might need to restart your http server...

I come from a windows background and I'm learning Cobalt so I might be wrong
at what
I said above but.. So if you know an easier way to tell httpd.conf to look
for
404, 403, 402 etc by default and not adding it to every virtual site post it
so we have it in the archives.  Than again, what if you have it setup and
you look
for a page that does not exist and than it looks for the /404.html and they
don't have
that either, nnna... it wouldn't go into a loop...

Last time I did came across that is when I did a .htaccess and deny an IP
address
but the no auth page pointed to /noaccess.htm so the web server was trying
to point
them back into the site at the /noaccess.htm page and would go into a loop.

I than did a http://othersite.com/noaccess.htm (off site) and the Denied IPs
would
be routed there.

I hope I am making sense... and might be a little off topic...?