[ms4w-users] ms4w - Application protection with password

Ian Tidy IANT at napier.govt.nz
Tue Feb 19 14:31:31 EST 2008


Emmanuel,
 
Try something like this:
<Directory /var/www/sec>
    Options FollowSymLinks
    AllowOverride None
    AuthType Basic
    AuthName "NCC Restricted Area"
    AuthBasicProvider file
    AuthUserFile /var/www/sec/.htpasswd
    Require valid-user
</Directory>
 
I put this in the httpd.conf, but it could be in another files, just
make sure you "Include" it.  You also need to enable the Authentication
Modules in the httpd.conf file.  Also it is NOT a smart idea to put your
password file inside the website.  You also need to use htpasswd (or
something similar) to create and maintain your password file.
 
Have a look at http://httpd.apache.org/docs/2.2/howto/auth.html and
http://httpd.apache.org/docs/2.2/howto/htaccess.html for more details.

Cheers Ian 
______________________
Ian Tidy
GIS Analyst / Developer
Works Asset Department
Napier City Council
mailto:iant at napier.govt.nz
http://www.napier.govt.nz <http://www.napier.govt.nz/>  |
http://maps.napier.govt.nz <http://maps.napier.govt.nz/>  

 

________________________________

From: ms4w-users-bounces at lists.maptools.org
[mailto:ms4w-users-bounces at lists.maptools.org] On Behalf Of E.Stefanakis
Sent: Wednesday, 20 February 2008 7:22 a.m.
To: ms4w-users at lists.maptools.org
Subject: [ms4w-users] ms4w - Application protection with password


Dear friends

I have defined the following (as described in the ms4w installation
notes) 
in order to protect an ms4w application with password; but it does not
work...
(I tried it in Windows Vista)

=============
The application resides at c:/ms4w/apps/ITE/htdocs

The C:\ms4w\apps\ITE\htdocs\ht.acl file contains the following:

   AuthType Basic
   AuthUserFile "c:/ms4w/Apache/bin/passwdkml.txt"
   AuthName "Password Required"

   require valid-user
 
The C:\ms4w\httpd.d\httpd_ITE.conf file contains the following:

   Alias /ITE/ "/ms4w/apps/ITE/htdocs/"

   <Directory "/ms4w/apps/ITE/htdocs/">
     AllowOverride AuthConfig
     Options Indexes FollowSymLinks Multiviews
   </Directory>

I have also added the following to the C:\ms4w\Apache\conf\httpd.conf

   AccessFileName  ht.acl .htcaccess

================

Any help would be greatly appreciated

Thanks in advance!

Emmanuel.

________________________________

This e-mail message has been scanned for Viruses and Content and cleared
by MailMarshal 
________________________________

Scanned by Bizo EmailFilter
<http://www.bizoservices.com/services/email_filter.html>  

#####################################################################################
This e-mail message has been scanned for Viruses and Content and cleared 
by MailMarshal
#####################################################################################

######################################################################
Attention: 
This e-mail message and accompanying data may contain information that
is confidential and subject to legal privilege. Any information
provided is given in good faith. However unless specifically stated to
the contrary, Napier City Council accepts no liability for the
content of this e-mail or for the consequences of any action taken on
the basis of the information provided, unless that information is
subsequently confirmed in writing. If you are not the intended recipient,
you are notified that any use, dissemination, distribution or copying
of this message or data is prohibited. If you received this e-mail
message in error, please notify us immediately and erase all copies
of this message and attachments. Thank you.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.maptools.org/pipermail/ms4w-users/attachments/20080220/8c09141a/attachment.html


More information about the ms4w-users mailing list