New .htaccess/.htpasswd problem

Need help installing PHP, configuring a script, or configuring a server? Then come on in and post your questions! We'll try to help the best we can!

Moderator: General Moderators

Post Reply
Labbat
Forum Newbie
Posts: 15
Joined: Mon Jan 26, 2004 9:10 pm

New .htaccess/.htpasswd problem

Post by Labbat »

I got some good out of my problem here:
In my htaccess file I have this

AuthName "Secure Area"
AuthUserFile root/".htpasswd"
AuthType Basic

<Limit GET>
require valid-user
</Limit>


Note where it says AuthUserFile root/".htpasswd"
My question is, is that an absolute path?
Im told it has to be absolute....
I finally got it to work - meaning
I got the login to pop up when I go to
http://142.59.59.29/www/admin/
However, it still isn't reconizing my username/password
Now, in Command prompt I do everything right, I type:

cd "\Program Files\Apache Group\Apache\bin"
Next, I type

htpassword -c "C:\Program Files\Apache Group\Apache\.htpasswd username

Now, note where I put ' username ' at the end there.
I can replace the word 'username' with whatever I want my username to be correct??

Anyway next, after I type that, it asks me to type my password, so I type it, then it asks me to type it again, and I type it, then it says "Adding password for username"

So everything works as it should, as I mentioned its just the login..
When I go to the url
(http://142.59.59.29/www/admin/) The login pops up, but it doesn't reconize my username and pw....
Try for yourself username: jeff password: iloveyou


Thanks
User avatar
ol4pr0
Forum Regular
Posts: 926
Joined: Thu Jan 08, 2004 11:22 am
Location: ecuador

Post by ol4pr0 »

Did you even bother to look @ this ???

viewtopic.php?t=17735
Labbat
Forum Newbie
Posts: 15
Joined: Mon Jan 26, 2004 9:10 pm

Re:

Post by Labbat »

AuthUserFile .htpasswd
AuthGroupFile /dev/null
AuthName "My Dog Did A Meep On The Rug"
AuthType Basic
AuthUserFile C:\Program Files\Apache Group\Apache\htdocs\www\admin\
deny from <someip> for exmple


Yes, I did look at it...
I dont understand where you put /dev/null
Where is that supposed to point?
And I assume the AuthUserFile is where the htaccess points...
And the line underneath that
Deny from <someip> for example/ I dont understand what you mean there, either...
User avatar
twigletmac
Her Royal Site Adminness
Posts: 5371
Joined: Tue Apr 23, 2002 2:21 am
Location: Essex, UK

Post by twigletmac »

Moved to Micellaneous - not a PHP question.

Mac
User avatar
ol4pr0
Forum Regular
Posts: 926
Joined: Thu Jan 08, 2004 11:22 am
Location: ecuador

Post by ol4pr0 »

Just cut out the lines


with the

Code: Select all

/dev/null/

and 

deny 200.8.0.0.0 

if you do not know the usage ..
they are just a thing i used.. you can cut it out..

for learnign more about deny ip and auth group you ll have to urn:doGooglesearch the i-net ;-)

the lines above will just make youre htaccess work..

and yes the authfile is where youre htpwd is located ;-)

happy hunting
Post Reply