diff options
author | Andrew Arnott <andrewarnott@gmail.com> | 2013-02-03 07:19:20 -0800 |
---|---|---|
committer | Andrew Arnott <andrewarnott@gmail.com> | 2013-02-03 07:19:20 -0800 |
commit | 778328ec797299ed6aa01279b3ccbf1eb15258bd (patch) | |
tree | d21ec38d500885d7bf82e06e73490bfb7b9f2650 /src/DotNetOpenAuth.Core | |
parent | ca038238a457c8c591032b621e18bb8382c3ed7d (diff) | |
parent | 3d5be0512a0208c58a96de74254fceacd83042a2 (diff) | |
download | DotNetOpenAuth-778328ec797299ed6aa01279b3ccbf1eb15258bd.zip DotNetOpenAuth-778328ec797299ed6aa01279b3ccbf1eb15258bd.tar.gz DotNetOpenAuth-778328ec797299ed6aa01279b3ccbf1eb15258bd.tar.bz2 |
Merge remote-tracking branch 'aarnott/v4.1' into v4.1
Diffstat (limited to 'src/DotNetOpenAuth.Core')
-rw-r--r-- | src/DotNetOpenAuth.Core/Loggers/Log4NetLogger.cs | 2 | ||||
-rw-r--r-- | src/DotNetOpenAuth.Core/Messaging/MessagingUtilities.cs | 3 |
2 files changed, 4 insertions, 1 deletions
diff --git a/src/DotNetOpenAuth.Core/Loggers/Log4NetLogger.cs b/src/DotNetOpenAuth.Core/Loggers/Log4NetLogger.cs index 293a6b2..01da034 100644 --- a/src/DotNetOpenAuth.Core/Loggers/Log4NetLogger.cs +++ b/src/DotNetOpenAuth.Core/Loggers/Log4NetLogger.cs @@ -201,6 +201,8 @@ namespace DotNetOpenAuth.Loggers { return IsLog4NetPresent ? CreateLogger(name) : null; } catch (FileLoadException) { // wrong log4net.dll version return null; + } catch (TargetInvocationException) { // Thrown due to some security issues on .NET 4.5. + return null; } catch (TypeLoadException) { // Thrown by mono (http://stackoverflow.com/questions/10805773/error-when-pushing-dotnetopenauth-to-staging-or-production-environment) return null; } diff --git a/src/DotNetOpenAuth.Core/Messaging/MessagingUtilities.cs b/src/DotNetOpenAuth.Core/Messaging/MessagingUtilities.cs index 69b111d..7aa4469 100644 --- a/src/DotNetOpenAuth.Core/Messaging/MessagingUtilities.cs +++ b/src/DotNetOpenAuth.Core/Messaging/MessagingUtilities.cs @@ -1927,7 +1927,8 @@ namespace DotNetOpenAuth.Messaging { // the public URL: if (serverVariables["HTTP_HOST"] != null) { ErrorUtilities.VerifySupported(request.Url.Scheme == Uri.UriSchemeHttps || request.Url.Scheme == Uri.UriSchemeHttp, "Only HTTP and HTTPS are supported protocols."); - string scheme = serverVariables["HTTP_X_FORWARDED_PROTO"] ?? request.Url.Scheme; + string scheme = serverVariables["HTTP_X_FORWARDED_PROTO"] ?? + (string.Equals(serverVariables["HTTP_FRONT_END_HTTPS"], "on", StringComparison.OrdinalIgnoreCase) ? Uri.UriSchemeHttps : request.Url.Scheme); Uri hostAndPort = new Uri(scheme + Uri.SchemeDelimiter + serverVariables["HTTP_HOST"]); UriBuilder publicRequestUri = new UriBuilder(request.Url); publicRequestUri.Scheme = scheme; |