Use URL Authorization
From Guidance Share
- J.D. Meier, Alex Mackman, Michael Dunner, Srinath Vasireddy, Ray Escamilla and Anandha Murukan
To allow anonymous access to public pages, use the following <authorization> element.
<system.web> <authorization> <allow users="*" /> </authorization> </system.web>
Use the following <authorization> element inside a <location> element in Web.config to deny access to unauthenticated users and force a redirect to the login page that is specified on the <forms> element:
<location path="Secure" > <system.web> <authorization> <deny users="?" /> </authorization> </system.web> </location>
[edit]
References
- See Building Secure ASP.NET Pages and Controls at http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnnetsec/html/THCMCh10.asp