Solved

Visual Studio: Password protect a site

Posted on 2008-10-23
3
209 Views
Last Modified: 2013-11-26
I have a web application created using Visual Studio 2008.  I want users to be denied access to the site if they are not logged in first.  I want the user trying to access a page without logging in to be redirected to the login page.
0
Comment
Question by:sproctor722
  • 2
3 Comments
 
LVL 20

Accepted Solution

by:
brwwiggins earned 125 total points
ID: 22789535
<authentication mode="Forms">
<forms name="AppLogin" loginUrl="login.aspx" path="/" protection="All" timeout="60"></forms>
</authentication>
<authorization>
      <deny users="?" />
 </authorization>
0
 
LVL 20

Expert Comment

by:brwwiggins
ID: 22789559
sorry, hit submit on wrong windows. The above should go in your web.config
0
 

Author Closing Comment

by:sproctor722
ID: 31509354
You're fantastic!  Thank you!!!!!
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Hangfire / asp.net sample 3 30
Paging GridView 7 34
Format column on datatable 7 18
Birthdays 3 21
The object model of .Net can be overwhelming at times – so overwhelming that quite trivial tasks often take hours of research. In this case, the task at hand was to populate the datagrid from SQL Server database in Visual Studio 2008 Windows applica…
For those of you who don't follow the news, or just happen to live under rocks, Microsoft Research released a beta SDK (http://www.microsoft.com/en-us/download/details.aspx?id=27876) for the Xbox 360 Kinect. If you don't know what a Kinect is (http:…
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at http://bit.ly/XDcourse.
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now