Forms Authentication and Login Pages

D

Dave

Hi,

I am creating a web application which have two different login areas. One
for members and one for administrators. Currently, I am using forms
authentication to validate the login for administrators as shown below. This
works perfectly fine but I now need to add another login authentication for
members which redirects them to a different login page if they are not
authenticated. Does anyone know how I would add this to the web.config file?


<configuration>
<system.web>
<authentication mode="Forms">
<forms name="..admin" path="/" loginUrl="/admin/login.aspx"
protection="All" timeout="30"/>
</authentication>
</system.web>
<location path="admin/documents">
<system.web>
<authorization>
<deny users="?"/>
<allow users="*"/>
</authorization>
</system.web>
</location>
</configuration>


Thanks,
Dave
 
D

David Waz...

Could use more info.... but

If you have a separate web application, you can place the security
information inside THAT applications Web.Config file, instead of trying to
do double duty on a single app.

If you are trying to class users as "admin" and "Normal", you can store that
information in the encrypted cookie as the security value, and extract that
value on page-load to verify authorization.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,994
Messages
2,570,223
Members
46,810
Latest member
Kassie0918

Latest Threads

Top