Author: amiraryani | Posted on: 1/4/2009 7:48:55 PM | Views : 309

I got a problem with authentication. I have two websites developed by ASP.Net 3.5, deployed to the production environment and both use Form Authentication. If a user access these sites from two tabs of an explorer, as soon as he login in the second website it reset the authentication on the first website, i.e, change Request.IsAuthenticated to False and Me.Page.User.Identity.Name to BLANK.
In both websites:

<authentication mode="Forms"/> set in the web.config

And there is login page which authenticate the user with a code such as

Protected Sub Login1_Authenticate(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.AuthenticateEventArgs) Handles Login1.Authenticate

    If Login1.UserName = "U1" And Login1.Password = "PASS" Then

      FormsAuthentication.RedirectFromLoginPage(Login1.UserName, False)

      e.Authenticated = ...

Go to the complete details ...