internal ExchangePrincipal CreateExchangePrincipal() { ExchangePrincipal result = null; try { OwaDiagnostics.TracePfd(18057, "Creating new ExchangePrincipal", new object[0]); if (ExTraceGlobals.CoreTracer.IsTraceEnabled(TraceType.DebugTrace)) { string text = null; using (WindowsIdentity current = WindowsIdentity.GetCurrent()) { text = current.Name; } if (string.IsNullOrEmpty(text)) { text = "<n/a>"; } string arg = this.SafeGetRenderableName(); ExTraceGlobals.CoreTracer.TraceDebug <string, string>(0L, "Using accout {0} to bind to ExchangePrincipal object for user {1}", text, arg); } result = this.InternalCreateExchangePrincipal(); } catch (ObjectNotFoundException ex) { bool flag = false; DataValidationException ex2 = ex.InnerException as DataValidationException; if (ex2 != null) { PropertyValidationError propertyValidationError = ex2.Error as PropertyValidationError; if (propertyValidationError != null && propertyValidationError.PropertyDefinition == MiniRecipientSchema.Languages) { OWAMiniRecipient owaminiRecipient = this.FixCorruptOWAMiniRecipientCultureEntry(); if (owaminiRecipient != null) { try { result = ExchangePrincipal.FromMiniRecipient(owaminiRecipient, RemotingOptions.AllowCrossSite); flag = true; } catch (ObjectNotFoundException) { } } } } if (!flag) { throw ex; } } return(result); }
// Token: 0x06001334 RID: 4916 RVA: 0x000772B0 File Offset: 0x000754B0 internal static void SetProxyRequestUrl(OwaContext owaContext) { UriBuilder uriBuilder = new UriBuilder(owaContext.HttpContext.Request.Url); Uri uri = uriBuilder.Uri; uriBuilder = new UriBuilder(owaContext.SecondCasUri.Uri); uriBuilder.Path = uri.AbsolutePath; string text = uri.Query; if (text.StartsWith("?", StringComparison.Ordinal)) { text = text.Substring(1, text.Length - 1); } uriBuilder.Query = text; Uri uri2 = uriBuilder.Uri; OwaDiagnostics.TracePfd(23177, "The request will be proxied to \"{0}\"", new object[] { uri2 }); owaContext.SetInternalHandlerParameter("pru", uri2); }