If I have a user "A" logged in, then when user "B" pulls up the site (without logging in), then user "A" custom identitiy properties are lost. This also occurs if both users are logged in and one of the users logs out.
The custom pricipal object is being stored in session. Session is being maintained by Asp.Net Session State Service.
Private Sub ShellApplication_AcquireRequestState(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.AcquireRequestState If (TypeOf HttpContext.Current.Handler Is IRequiresSessionState) Then If (Csla.ApplicationContext.AuthenticationType = "Windows") Then Exit Sub End If Dim principal As System.Security.Principal.IPrincipal Try principal = CType(Session(SessionKey.CslaPrincipal), System.Security.Principal.IPrincipal) Catch principal = Nothing End Try If (principal Is Nothing) Then If User.Identity.IsAuthenticated AndAlso TypeOf User.Identity Is FormsIdentity Then formsAuth.SignOut() End If PHGTPrincipal.Logout() Else ' use the principal from Session Csla.ApplicationContext.User = principal End If End If End Sub
I am using CSLA 4.1. I have csla.dll, csla.web.dll, and csla.web.mvc.dll referenced in my projects.
Any help would be GREATLY appreciated!
Maybe this thread would help:
Copyright (c) Marimer LLC