Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 08 Mar 2001 16:53:14 -0800
From:      Drew Tomlinson <drewt@writeme.com>
To:        'Drew Tomlinson' <drewt@writeme.com>, 'Tony Wells' <awells@journalstar.com>, "'Gerald T. Freymann'" <gerry@eagle.ca>
Cc:        "FreeBSD Questions (E-mail)" <freebsd-questions@FreeBSD.ORG>
Subject:   RE: Apache Help (.htaccess) - SOLVED
Message-ID:  <BA5D0CE1CBB2D411B6AA00A0CC3F02390AF8C5@ldcmsx01.lc.ca.gov>
In-Reply-To: <BA5D0CE1CBB2D411B6AA00A0CC3F02390AF8C3@ldcmsx01.lc.ca.gov>

next in thread | previous in thread | raw e-mail | index | archive | help
I did some more browsing on the web and ran across a web site called Apache
Today.  There was an article
(http://apachetoday.com/news_story.php3?ltsn=2000-07-19-002-01-NW-LF-SW) on
using .htaccess files.  I reviewing the section on Overrides, I figured out
that I needed to modify the AllowOverride directive in my (almost) default
httpd.conf file from "None" to "All".  See below.

#
# This controls which options the .htaccess files in directories can
# override. Can also be "All", or any combination of "Options", "FileInfo",
# "AuthConfig", and "Limit"
#
    AllowOverride All

In reading the section, there are specific things that you can allow
override on.  I chose "all" because I don't really understand what all the
different things are.  I only mention this because by stating "All" you may
be introducing security risks into your server that you are not aware of.
My particular situation is that there is nothing on my server that I really
need to worry about as it is only for my personal development.  Your
security requirements may be greater and I would urge you to consider this
before following my example.

In any event, the .htaccess file works as I expected.  Thank you to all for
your help!

Drew

> -----Original Message-----
> From: Drew Tomlinson [mailto:drewt@writeme.com]
> Sent: Thursday, March 08, 2001 3:36 PM
> To: 'Tony Wells'; 'Gerald T. Freymann'
> Cc: FreeBSD Questions (E-mail)
> Subject: RE: Apache Help (.htaccess)
>
>
>
>
> > -----Original Message-----
> > From: Tony Wells [mailto:awells@journalstar.com]
> > Sent: Thursday, March 08, 2001 11:55 AM
> > To: Drew Tomlinson
> > Cc: FreeBSD Questions (E-mail)
> > Subject: Re: Apache Help (.htaccess)
> >
> >
> > That page looks pretty complete.  Are you using an absolute path for
> > your password file in your .htaccess?
>
> Yes.  I'm expecting my browser to prompt me for a password whenever I
> attempt to access a file in the protected directory.  This is
> what it's
> supposed to do, right?
>
> So assuming it is, my password file is
> /usr/local/etc/apache/password.  My
> web data is in /usr/local/share/doc/apache/dir/protected.dir.  I have
> created a file called .htaccess in protected.dir and used
> htpasswd to create
> my password file.  I used the -c option for the first allowed
> user and then
> dropped the -c to add addtional users.  So, here is my .htaccess file:
>
> 114 Blacksheep# cat .htaccess
> AuthUserFile /usr/local/etc/apache/password
> AuthGroupFile /dev/null
> AuthName "Protected Directory"
> AuthType Basic
>
> <Limit GET POST PUT>
> require user user1 user2
> </Limit>
>
> I've issued a kill -1 `cat /var/run/httpd.pid` to see if that
> would make the
> password required.  It didn't.  I then rebooted my machine
> but that did not
> help either.  Do you have any idea why this isn't working?
>
> Thanks for your help!
>
> Drew
>
> > Drew Tomlinson wrote:
> > >
> > > I followed the directions at
> > http://kb.indiana.edu/data/abeq.html?cust=2008
> > > to password protect one of my web directories using a
> .htaccess and
> > > corresponding password file but it is not working.  Does
> > anyone have any
> > > ideas on what I may have overlooked?  What can I post or
> > where can I look to
> > > help diagnose this problem.
> > >
> > > Thanks,
> > >
> > > Drew
> > >
> > > To Unsubscribe: send mail to majordomo@FreeBSD.org
> > > with "unsubscribe freebsd-questions" in the body of the message
> >
> > To Unsubscribe: send mail to majordomo@FreeBSD.org
> > with "unsubscribe freebsd-questions" in the body of the message
> >
>
>
> To Unsubscribe: send mail to majordomo@FreeBSD.org
> with "unsubscribe freebsd-questions" in the body of the message
>


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?BA5D0CE1CBB2D411B6AA00A0CC3F02390AF8C5>