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

What is a cloud service, What is a Cloud Service? A cloud service is us...

What is a Cloud Service? A cloud service is used to build cloud applications. This service gives the facility of using the cloud application without installing it on the comput

I want windows 8.1 metro style app development, I want Windows 8.1 Metro st...

I want Windows 8.1 Metro style app development Project Description: I want Windows 8 & 8.1 metro style app development - Media Player application Skills required are C# Pr

Nested classes, What is nested Classes? You can access an array using t...

What is nested Classes? You can access an array using the INDEX value of that array, but how many times you know the real value of the index. The Hashtable provides a way of ac

Appsetting section in "web.config" file, What is AppSetting Section in "Web...

What is AppSetting Section in "Web.Config" file? Web.config file describe the configuration for a webproject. By Using "AppSetting" section we can define user defined values. T

I need cell phone pinging for fugitive tracking, I need CELL PHONE PINGING ...

I need CELL PHONE PINGING for fugitive tracking Project Description: I want an application like the following: it provides cell phone pinging(location information via gps) wi

What are the benefits of using of ado.net in .net 4.0, What are the benefit...

What are the benefits of using of ADO.NET in .NET 4.0. The following are the benefits of using ADO.NET in .NET 4.0 are as follows: Language-Integrated Query (LINQ) - Adds

I require to syn my microsoft exchange calendar, Google Calendar Project...

Google Calendar Project Description: I require to syn my Microsoft exchange calendar with the Google calendar so i will view the all the changes that happen in Microsoft exch

How to increase sql performance?, How can you increase SQL performance? ...

How can you increase SQL performance? 1)Keep your indexes as narrow as possible. This reduces the size of the index and decrease the number of reads needed to read the index.

What is windows workflow foundation, What is Windows Workflow Foundation (W...

What is Windows Workflow Foundation (WF)? Windows Workflow Foundation (WF) is a technology that was first introduced in .NET Framework 3.0. WF having of a programming model, a

I need desktop app for website, I need Desktop App for website Project D...

I need Desktop App for website Project Description: We own a big website. Basically we want a desktop app or mobile app for our website. So people download and have our websi

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