Author |
|
puertoblack2003
Joined: 31 Jul 2009 Posts: 121 Location: U.S
|
Posted: Mon 10 Mar '14 3:15 Post subject: password protect directory |
|
|
Can someone share the proper way. to password protect a directory for apache 2.4.7. Information i gather seems to not work.
Thanks in advance |
|
Back to top |
|
glsmith Moderator
Joined: 16 Oct 2007 Posts: 2268 Location: Sun Diego, USA
|
Posted: Mon 10 Mar '14 4:07 Post subject: |
|
|
how about you tell us what you have tried .. so someone can point you in the right direction and maybe explain where you are going wrong |
|
Back to top |
|
puertoblack2003
Joined: 31 Jul 2009 Posts: 121 Location: U.S
|
Posted: Mon 10 Mar '14 4:31 Post subject: |
|
|
glsmith wrote: | how about you tell us what you have tried .. so someone can point you in the right direction and maybe explain where you are going wrong |
sorry about that do make since
ok in my vhost file i have this.
Code: | <Directory "F:/Abyss Web Server/private">
Options FollowSymLinks Multiviews Indexes
AllowOverride None
AuthType basic
AuthName "private"
AuthUserFile "F:/Abyss Web Server/private/.htpasswd"
Require valid-user
</Directory>
<Directory "F:/Abyss Web Server/private">
Require all denied
</Directory> |
In my file directory that i want password protected there's a htaccess with this info
Code: | AuthType Basic
AuthName "Authentication Required"
# Optional line:
AuthBasicProvider file
AuthUserFile "F:/Abyss Web Server/private/.htpasswd"
AuthGroupFile "F:/Abyss Web Server/private/.htgroup"
Require group admins |
And with that it still dont work when i go to the directory via browser the pop up box to enter username and pass |
|
Back to top |
|
glsmith Moderator
Joined: 16 Oct 2007 Posts: 2268 Location: Sun Diego, USA
|
Posted: Mon 10 Mar '14 4:40 Post subject: |
|
|
AllowOverride must set to AuthConfig not none and it needs to be set that way in httpd.conf for the <Directory> you are going to password protect. |
|
Back to top |
|
puertoblack2003
Joined: 31 Jul 2009 Posts: 121 Location: U.S
|
Posted: Mon 10 Mar '14 5:15 Post subject: |
|
|
glsmith wrote: | AllowOverride must set to AuthConfig not none and it needs to be set that way in httpd.conf for the <Directory> you are going to password protect. |
ok thank you. It's seem to work but, not what i expected.
for my forum if i click on the admin link here http://www.mysite.org/myadminpanel/index.php the pop up login window wont appear if i remove this to folder then it will
http://www.mysite.org/myadminpanel/
I tried to convert everything over coming from 2.2.26 this part is my last obstacles.
thank you for your help |
|
Back to top |
|