Solved

Asp.net - default login and "Permission denied" pages

Posted on 2010-09-22
2
487 Views
Last Modified: 2012-05-10
How do I redirect a user to a login page that is not the default ~/Account/Login.aspx?

And how do I redirect a user to a default "Permission Denied" page?
0
Comment
Question by:Rick
2 Comments
 
LVL 51

Expert Comment

by:HainKurt
ID: 33737836
create this page

~/Account/Login.aspx?

add this into it

server.transfer("newpath/newpage.aspx", true)
0
 
LVL 13

Accepted Solution

by:
Onthrax earned 500 total points
ID: 33738852
You can alter your web.config to change the default login aspx page.


<authentication mode="Forms">
<forms loginUrl = "frmLogin.aspx" name="3345C" timeout="1"/>
</authentication>

as to the redirect. You need to verify authentication after the login button has been pressed and use the server.transfer method to redirect to a permission denied page.
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (http://www.ecb.europa.eu/stats/exch…
Entity Framework is a powerful tool to help you interact with the DataBase but still doesn't help much when we have a Stored Procedure that returns more than one resultset. The solution takes some of out-of-the-box thinking; read on!
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…

760 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

21 Experts available now in Live!

Get 1:1 Help Now