|
|
| Author |
Message |
kireol
RealPoor Master of Posts

Joined: 02 Aug 2003 Posts: 9517
Location: Royal Oak, MI
|
Posted: 10/05/03 - 12:05 Post subject: apache windows .htaccess question
|
|
|
I'm running apache under windows.
Trying to set up .htaccess
Read like 92837423894 web pages and somethings still wrong.
Here's what i have so far....
Want to protect my directory /admin (yes I know htaccess isnt very secure)
-----------my .htaccess file (in admin folder)-----------
AuthName "restricted"
AuthType Basic
AuthUserFile /www/htdocs/admin/.htpasswd
<LIMIT GET POST>
require valid-user
</LIMIT>
-------------my .htpasswd file (in admin folder)-------------
chris:$apr1$17/.....$FsoBZpXM08iUEEyFrTRxh1
I dont think i have the authuserfile correct. but i cant figure it out. if you go to http://kireol.redirectme.net/admin you can see that it does find the .htaccess file. But I dont think .htaccess is pointing to the correct spot for the .htpasswd file. I've tried using things like "c:/program files/apache group/apache/htdocs/admin/.htpasswd" but that doesnt work either.
any ideas? I've set this up in linux like a hundred times. first time in windows though
|
|
|
Back to top
|
|
|
|
 |
khrath
RealPoor Master of Posts

Joined: 11 Oct 2002 Posts: 8750
|
Posted: 10/05/03 - 13:18 Post subject:
|
|
|
|
why you using windows =(
|
|
|
Back to top
|
|
|
|
 |
kireol
RealPoor Master of Posts

Joined: 02 Aug 2003 Posts: 9517
Location: Royal Oak, MI
|
Posted: 10/05/03 - 13:19 Post subject:
|
|
|
|
cuz it's for my dad, and he can barely use windows let alone linux =(
|
|
|
Back to top
|
|
|
|
 |
Stixl
Luke Warm

Joined: 05 May 2003 Posts: 185
|
Posted: 10/05/03 - 13:35 Post subject:
|
|
|
http://apache-server.com/tutorials/ATusing-htaccess.html
Pretty good summary there of getting apache running under windows. Make sure you assign the container correctly, renaming that file and redirecting to it looks pretty important. Hell you've prolly already read that page if you went through 92837423894 pages.
Looking at your config it appears set up correctly; try following the guidelines outlined in that page (renaming the file, pointing to it etc) and see if that works. Windows doesnt like files with .htaccess extensions me no think)
|
|
|
Back to top
|
|
|
|
 |
kireol
RealPoor Master of Posts

Joined: 02 Aug 2003 Posts: 9517
Location: Royal Oak, MI
|
Posted: 10/05/03 - 13:47 Post subject:
|
|
|
| Stixl wrote: | http://apache-server.com/tutorials/ATusing-htaccess.html
Pretty good summary there of getting apache running under windows. Make sure you assign the container correctly, renaming that file and redirecting to it looks pretty important. Hell you've prolly already read that page if you went through 92837423894 pages.
Looking at your config it appears set up correctly; try following the guidelines outlined in that page (renaming the file, pointing to it etc) and see if that works. Windows doesnt like files with .htaccess extensions me no think) |
thx stixl. still no luck. ya, i thought about windows with the file name. but i tried just a normal name "users.pwd" and no luck, and it also tells me something that it finds the .htaccess file and does use it
/frustrated
|
|
|
Back to top
|
|
|
|
 |
Stixl
Luke Warm

Joined: 05 May 2003 Posts: 185
|
Posted: 10/05/03 - 13:59 Post subject:
|
|
|
.htacess is similar to an access list on a router.
There is an explicit deny all/all on an access list. However, with .htaccess files, there is an implicit Satisfy any.
Try changing it to Satisfy All, see what that does
|
|
|
Back to top
|
|
|
|
 |
Stixl
Luke Warm

Joined: 05 May 2003 Posts: 185
|
Posted: 10/05/03 - 14:08 Post subject:
|
|
|
bah looked at it closer.
You need to add quotes around you password file:
AuthUserFile "/www/htdocs/admin/.htpasswd"
second, your directory container class in the httpd.conf file, you need to set the AllowOverride option All or AuthConfig
<Directory ".../apache/htdocs" [or whatever that folder is]>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
Allow from all
</Directory>
see if that works man. apache in windows is a b***h
|
|
|
Back to top
|
|
|
|
 |
khrath
RealPoor Master of Posts

Joined: 11 Oct 2002 Posts: 8750
|
Posted: 10/05/03 - 16:04 Post subject:
|
|
|
also, more than likely, your dad doesn't need everything on override. Theres certain things disabled for a reason.
AllowOverride All = Not for your daddy
|
|
|
Back to top
|
|
|
|
 |
|
|