[KLUG Members] Have any of you successfully implemented .htaccess/.htpasswd functionality on your or your ISP servers?

members@kalamazoolinux.org members@kalamazoolinux.org
Tue, 19 Nov 2002 14:06:27 -0500


>From what I understand, .htaccess and .htpasswd are two ASCII files
>with no 'file' names ... the .htaccess and .htpasswd actually represent the 
>file extensions.

Eh? .htacces and .htpasswd are the file names.  So the file name starts with a
dot?  There is no such thing as an "extension", even though some poorly designed
operating systems make a big deal about the concept.  "fred.txt" is the name of
a file,  the occurance of a period in the file name is irrelevant.

>.htaccess is an ASCII text "entity" that contains various
>directives that will be interpreted by an Apache Server,

Yes.

>while .htpasswd is
>is simply an ASCII text "entity" that contains the typical username and
encrypted password combo, i.e., rob:xYZ123qUS or sometime
>similar.

I think so, I've not used .htpasswd.  I believe the password file can be called
anything you want. (actually so can .htaccess, but that is rarely changed).

 
> "AuthUserFile /www/htdocs/domains/xyz.com/webdocs/.htpasswd
> AuthGroupFile /dev/null
> AuthName "PD Documents"
> AuthType Basic
> require user rob"

I would expect to see something like
<File yoyomama.pdf>
 AuthUserFile /www/htdocs/domains/xyz.com/webdocs/.htpasswd
 AuthGroupFile /dev/null
 AuthName "PD Documents"
 AuthType Basic
 require user rob"
</File>

> I'm getting the prompt, but I'm not passing mustard here when it comes
> to linking up to the .htpasswd ASCII file.  I've got something wrong.
> Either the full pathname to the .htpasswd entity (although I checked
> with ISP and used what they gave me ;>)) is incorrect, or perhaps an
> Apache directive is missing.

See anything in /var/log/httpd/error_log?  Or whereever for access and error
logs are.

> I'm trying to implement this on an ISP's machine and while they offer
> this functionality, the folks there don't seem to be really
> knowledgeable of the

Theres a shock!

>I've looked at a number of .htaccess tutorials, the apache org web
>site and a few newsgroups ... what's sort of comical is ... I am not
>alone!  But the sad thing is ... those on the newsgroups don't seem to
>have any real constructive suggestions ... it's more like "trial and
>error" ... which, of course, is a learning process in and of itself.

Unfortunately I can't point you to a good .htaccess intro, every thing I've seen
is lowsy.  The documentation of Apache access control is spotty at best.