Forms Authentication Webconfig

  • Thread starter Thread starter Beren
  • Start date Start date
B

Beren

Hello I've got a pretty urgent question.
I've just started to use the forms authentication of .NET
and to force the authentication I use

<forms ... loginUrl="login.aspx" ... />
<deny users="?"> to prevent anonymous access.

Now only login.aspx is accessible by ppl who haven't logged in.
How could I make another page to be excluded from this.
For example an about.aspx and default.aspx I don't want to protect.

Regards and thanks,

Beren
 
Check out:
http://www.devhood.com/tutorials/tutorial_details.aspx?tutorial_id=85

You are looking for something like:

<location path="admin/">
<system.web>
<authorization>
<allow users="devhood" />
<deny users="someguy" />
</authorization>
</system.web>
</location>
<location path="usersonly/">
<system.web>
<authorization>
<deny users="?" />
</authorization>
</system.web>
</location>
<location path="public/">
<system.web>
<authorization>
<allow users="*" />
</authorization>
</system.web>
</location>
 
Back
Top