Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 250
  • Last Modified:

For an internet website is it still okay to use forms authentication with cookies?

I am maintaining some code from a visual studio 2003 .net 1.1 application. It appears to be using Forms Authentication with cookies. Is this method of using forms authentication with cookies still a valid way of doing web page authorization and authentication? here is an example of some of the code:

                  FormsAuthentication.SignOut();
                  Request.Cookies.Clear();
0
brgdotnet
Asked:
brgdotnet
1 Solution
 
varungdCommented:
Try this code...
WebConfig
 
<authentication mode="Forms">
			<forms loginUrl="~/Security/Login.aspx"
				   protection="All"
				   defaultUrl="~/Common/ePanel_Default.aspx" 
				   timeout="30"
				   />
		</authentication>
 
		<authorization>
			<deny users="?" />
		</authorization>
 
 
Button click in login page
 
FormsAuthentication.RedirectFromLoginPage(txtLoginName.Text, false);
 
 
For signout
 
 FormsAuthentication.SignOut();
 Session.Abandon();
 Request.Cookies.Clear();

Open in new window

0
 
TechTiger007Commented:
Yes forms authentication and cookies is still a valid way of authentication over internet.

0
 
brgdotnetAuthor Commented:
Brief
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now