This commit is contained in:
Dave Tillman 2017-04-27 16:20:30 -06:00
Родитель 628639b858
Коммит 9cc0f6f6fd
8 изменённых файлов: 15 добавлений и 15 удалений

Просмотреть файл

@ -60,7 +60,7 @@ namespace Steeltoe.Security.Authentication.CloudFoundry
HttpRequestMessage requestMessage = GetTokenRequestMessage(code, redirectUri);
HttpClient client = GetHttpClient();
#if NET46
#if NET452
RemoteCertificateValidationCallback prevValidator = null;
if (!Options.ValidateCertificates)
{
@ -75,7 +75,7 @@ namespace Steeltoe.Security.Authentication.CloudFoundry
}
finally
{
#if NET46
#if NET452
ServicePointManager.ServerCertificateValidationCallback = prevValidator;
#endif
}
@ -100,7 +100,7 @@ namespace Steeltoe.Security.Authentication.CloudFoundry
HttpRequestMessage request = GetTokenInfoRequestMessage(tokens);
HttpClient client = GetHttpClient();
#if NET46
#if NET452
RemoteCertificateValidationCallback prevValidator = null;
if (!Options.ValidateCertificates)
{
@ -116,7 +116,7 @@ namespace Steeltoe.Security.Authentication.CloudFoundry
}
finally
{
#if NET46
#if NET452
ServicePointManager.ServerCertificateValidationCallback = prevValidator;
#endif
}

Просмотреть файл

@ -88,7 +88,7 @@ namespace Steeltoe.Security.Authentication.CloudFoundry
internal protected virtual HttpMessageHandler GetBackChannelHandler()
{
#if NET46
#if NET452
return null;
#else
if (!ValidateCertificates)

Просмотреть файл

@ -68,7 +68,7 @@ namespace Steeltoe.Security.Authentication.CloudFoundry
public JsonWebKey FixupKey(JsonWebKey key)
{
#if NET46
#if NET452
byte[] existing = Base64UrlEncoder.DecodeBytes(key.N);
TrimKey(key, existing);
@ -76,7 +76,7 @@ namespace Steeltoe.Security.Authentication.CloudFoundry
return key;
}
#if NET46
#if NET452
private void TrimKey(JsonWebKey key, byte[] existing)
{
byte[] signRemoved = new byte[existing.Length -1];
@ -92,7 +92,7 @@ namespace Steeltoe.Security.Authentication.CloudFoundry
requestMessage.Headers.Accept.Add(new MediaTypeWithQualityHeaderValue("application/json"));
HttpClient client = GetHttpClient();
#if NET46
#if NET452
RemoteCertificateValidationCallback prevValidator = null;
if (!Options.ValidateCertificates)
{
@ -107,7 +107,7 @@ namespace Steeltoe.Security.Authentication.CloudFoundry
}
finally
{
#if NET46
#if NET452
ServicePointManager.ServerCertificateValidationCallback = prevValidator;
#endif
}

Просмотреть файл

@ -7,7 +7,7 @@
<VersionPrefix>$(SteeltoeVersion)</VersionPrefix>
<VersionSuffix>$(VersionSuffix)</VersionSuffix>
<Authors>Pivotal;dtillman</Authors>
<TargetFrameworks>net46;netstandard1.5</TargetFrameworks>
<TargetFrameworks>net452;netstandard1.5</TargetFrameworks>
<AssemblyName>Steeltoe.Security.Authentication.CloudFoundry</AssemblyName>
<PackageId>Steeltoe.Security.Authentication.CloudFoundry</PackageId>
<PackageTags>CloudFoundry;ASPNET Core;Security;OAuth2;SSO</PackageTags>

Просмотреть файл

@ -7,7 +7,7 @@
<VersionPrefix>$(SteeltoeVersion)</VersionPrefix>
<VersionSuffix>$(VersionSuffix)</VersionSuffix>
<Authors>Pivotal;dtillman</Authors>
<TargetFrameworks>net46;netstandard1.5</TargetFrameworks>
<TargetFrameworks>net452;netstandard1.5</TargetFrameworks>
<AssemblyName>Steeltoe.Security.DataProtection.Redis</AssemblyName>
<PackageId>Steeltoe.Security.DataProtection.Redis</PackageId>
<PackageTags>CloudFoundry;ASPNET Core;Security;DataProtection;Redis</PackageTags>

Просмотреть файл

@ -90,7 +90,7 @@ namespace Steeltoe.Security.Authentication.CloudFoundry.Test
{
ValidateCertificates = false
};
#if NET46
#if NET452
Assert.Null(opts.GetBackChannelHandler());
#else
@ -118,7 +118,7 @@ namespace Steeltoe.Security.Authentication.CloudFoundry.Test
ValidateCertificates = false
};
#if NET46
#if NET452
Assert.Null(opts.GetBackChannelHandler());
#else

Просмотреть файл

@ -3,7 +3,7 @@
<Import Project="..\..\config\versions.props" />
<PropertyGroup>
<TargetFrameworks>netcoreapp1.1;net46</TargetFrameworks>
<TargetFrameworks>netcoreapp1.1;net452</TargetFrameworks>
<!-- Next two lines needed due to https://github.com/aspnet/Hosting/issues/926 -->
<GenerateBindingRedirectsOutputType>true</GenerateBindingRedirectsOutputType>
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>

Просмотреть файл

@ -3,7 +3,7 @@
<Import Project="..\..\config\versions.props" />
<PropertyGroup>
<TargetFrameworks>netcoreapp1.1;net46</TargetFrameworks>
<TargetFrameworks>netcoreapp1.1;net452</TargetFrameworks>
</PropertyGroup>
<ItemGroup>