[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[cobalt-users] .htaccess yet again
- Subject: [cobalt-users] .htaccess yet again
- From: "Edward Bishop" <eddie@xxxxxxxxxxxxxxxx>
- Date: Wed Feb 13 10:33:22 2002
- List-id: Mailing list for users to share thoughts on Cobalt products. <cobalt-users.list.cobalt.com>
This might well be in the archive, but I can't find it; it's one of
those that gives too many irrelevant hits when searching. I've looked
in the RaQFaQ and the wider web as well. Also it might not be
Cobalt-specific so apologies in advance.
Can .htaccess be used to require authorisation for access a directory
and then redirect the browser to a custom page if that authorisation
fails - ie if the user fails three times to supply a valid l/p?
Here's my .htaccess which should make it clear what I'm trying to do:
AuthPAM_Enabled off
AuthUserFile /home/sites/home/web/protected-directory/.htpasswd
AuthGroupFile /dev/null
AuthName "Authorised users only"
AuthType Basic
<Limit GET PUT POST>
require valid-user
</Limit>
ErrorDocument 403 http://www.mydomain.com/youfailed.htm
ErrorDocument 401 http://www.mydomain.com/youfailed.htm
I'm not sure whether the code returned is 403 or 401 so I'm trying
both. The authorisation bit is working fine but then I get the Cobalt
"Authorisation Required" page after three deliberate misses.
--
Eddie Bishop