コード例 #1
0
 // Token: 0x060002FF RID: 767 RVA: 0x0000FD28 File Offset: 0x0000DF28
 private void InitializeFromRehydratedIdentity()
 {
     if (this.clientSecurityContextWrapper != null)
     {
         AirSyncDiagnostics.TraceInfo(ExTraceGlobals.RequestsTracer, null, "[AirSyncUser.InitializeFromRehydratedIdentity]. clientSecurityContextWrapper is not null. calling dispose.");
         this.clientSecurityContextWrapper.Dispose();
     }
     this.clientSecurityContextWrapper = ClientSecurityContextWrapper.FromIdentity(((IAirSyncUser)this).Identity);
     this.username = ((IAirSyncUser)this).Identity.Name;
     AirSyncDiagnostics.TraceError <string>(ExTraceGlobals.RequestsTracer, null, "[AirSyncUser.InitializeFromRehydratedIdentity] Hyrdating CSC from user {0}", this.username);
     ((IAirSyncUser)this).InitializeADUser();
     ((IAirSyncUser)this).AcquireBudget();
 }
コード例 #2
0
 // Token: 0x06001549 RID: 5449 RVA: 0x0007C880 File Offset: 0x0007AA80
 public SecurityContextAndSession(ClientSecurityContextWrapper wrapper, MailboxSession session)
 {
     if (wrapper == null)
     {
         throw new ArgumentNullException("wrapper");
     }
     if (session == null)
     {
         throw new ArgumentNullException("session");
     }
     this.SecurityContextWrapper = wrapper;
     this.MailboxSession         = session;
     this.SecurityContextWrapper.AddRef();
 }
コード例 #3
0
 // Token: 0x06000300 RID: 768 RVA: 0x0000FD9C File Offset: 0x0000DF9C
 private void InitializeFromLoggedOnIdentity()
 {
     if (((IAirSyncUser)this).WindowsIdentity.User == null)
     {
         AirSyncDiagnostics.TraceError(ExTraceGlobals.RequestsTracer, null, "[AirSyncUser.InitializeFromLoggedOnIdentity] Anonymous user is forbidden.");
         this.context.ProtocolLogger.SetValue(ProtocolLoggerData.Error, "AnonymousUser");
         AirSyncPermanentException ex = new AirSyncPermanentException(HttpStatusCode.Forbidden, StatusCode.UserCannotBeAnonymous, EASServerStrings.AnonymousAccessError, true);
         throw ex;
     }
     this.windowsPrincipal = new WindowsPrincipal(((IAirSyncUser)this).WindowsIdentity);
     this.username         = this.context.Request.LogonUserName;
     if (this.clientSecurityContextWrapper != null)
     {
         AirSyncDiagnostics.TraceInfo(ExTraceGlobals.RequestsTracer, null, "[AirSyncUser.InitializeFromLoggedOnIdentity]. clientSecurityContextWrapper is not null. calling dispose.");
         this.clientSecurityContextWrapper.Dispose();
     }
     this.clientSecurityContextWrapper = ClientSecurityContextWrapper.FromWindowsIdentity(((IAirSyncUser)this).WindowsIdentity);
     AirSyncDiagnostics.TraceError <string>(ExTraceGlobals.RequestsTracer, null, "[AirSyncUser.InitializeFromLoggedOnIdentity] Acquired CSC for user '{0}'", this.username);
     ((IAirSyncUser)this).InitializeADUser();
     ((IAirSyncUser)this).AcquireBudget();
 }
コード例 #4
0
 // Token: 0x060004BC RID: 1212 RVA: 0x0001D433 File Offset: 0x0001B633
 public static ClientSecurityContextWrapper FromIdentity(IIdentity identity)
 {
     return(new ClientSecurityContextWrapper(ClientSecurityContextWrapper.ClientSecurityContextFromIdentity(identity)));
 }