Forms authentication, DOT NET Programming

Assignment Help:

Explain Forms authentication in detail.

In the old ASP if you were said to create a login page and do authentication you have to do lot of custom coding. But now in ASP.NET that is made easy by introducing Forms authentication. So let's view in detail what form authentication is.

The Forms authentication uses a ticket cookie to see that user is authenticated or not. That means that whenever  user is authenticated first time a cookie is set to tell that this user is authenticated.When  the cookies expire then Forms authentication mechanism sends the user to the login page.

The steps which define steps for Forms authentication are as follows:-

1) Configure Web.config file with forms authentication. As shown below in the config file you can see we have give the cookie name and loginurl page.

path="/" />

Remove the anonymous to access to the IIS web application, some changes are

Done to web.config file are as follows.

1) Create the login page which will accept the user information. You will have to create your login page that is the Login.aspx which will actually get the user data.

2) Finally a little bit coding in the login button.

Let's assume that the login page has2 textboxes: Txtname and txtapssword.

Also import the System.Web.Security and put the following code in the login button of the page.

If  Page.IsValid Then

If  FormsAuthentication.Authenticate(txtName.Text, txtPassword.Text) Then

FormsAuthentication.RedirectFromLoginPage(txtName.Text, False) Else

lblStatus.Text = "Error not proper user" End If

End If


Related Discussions:- Forms authentication

How can inheritance is achieved in vb.net?, How inheritance is achieved in ...

How inheritance is achieved in VB.NET? The Inheritance is achieved by using "Inherits" keyword in the VB.NET (& For C# it is ":"). Easy Sample is provided in CD for understandi

I need deatch-bycahpca api tutorial, I need deatch-bycahpca API tutorial ...

I need deatch-bycahpca API tutorial Please teach me how to use deatch-bycahpa API Skills required: Visual Basic, C# Programming

Application object and its difference from cache object, What is an applica...

What is an application object & how it is different from c ache object? The Application object can be used in many situations where we want the data to be shared across user

Calculate standard deviation - c# program, Calculate Standard Deviation - C...

Calculate Standard Deviation - C# Program Hello i am unable to find the code for Calculate Standard Deviation in c#. Can anybody please provide me the assignment help?

Urgently requires a jquery expert, Project Description: Looking for a JQ...

Project Description: Looking for a JQuery expert that will develop a customizable product selection page to work with our asp.net website. Product selection, size, quantity, pri

Web based program prepared with net c# and sql server, Project Description:...

Project Description: We have a web based program prepared with .NET C# and Microsoft SQL Server. There are some reports needs to be created. Required Skills. - High Pro

State the advantages of xml schemas over dtd, State the advantages of XML s...

State the advantages of XML schemas over DTD. Microsoft developed a language called as the XML Schema Definition (XSD) to explain the schema to an XML document. The following a

I need game development tutorials, I need Game development tutorials Pro...

I need Game development tutorials Project Description: We need video tutorials like lynda for game development using unity. You must have developed games before and need to s

What are the improvements made in cas in .net 4.0, What are the improvement...

What are the improvements made in CAS in .NET 4.0? The CAS mechanism in .NET is used to control and configure the ability of managed code. Previously, as this policy was applic

Grid view related query, i want to know how can i sum quantity column in g...

i want to know how can i sum quantity column in gridview and place it in first row...not in footer..in .net. Rply ASAP

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd