Use a post-typo HttpClientHelper method

This commit is contained in:
Tim Hess 2019-01-18 16:12:06 -06:00
Родитель 25f17f498e
Коммит 1ec6c160e7
5 изменённых файлов: 21 добавлений и 21 удалений

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

@ -89,7 +89,7 @@ namespace Steeltoe.Security.Authentication.CloudFoundry
HttpClient client = GetHttpClient();
HttpClientHelper.ConfigureCertificateValidatation(
HttpClientHelper.ConfigureCertificateValidation(
_validateCertificates,
out SecurityProtocolType prevProtocols,
out RemoteCertificateValidationCallback prevValidator);

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

@ -54,7 +54,7 @@ namespace Steeltoe.Security.Authentication.CloudFoundry
HttpRequestMessage requestMessage = GetTokenRequestMessage(requestParameters, targetUrl);
_logger?.LogDebug("Exchanging code {code} for token at {accessTokenUrl}", code, targetUrl);
HttpClientHelper.ConfigureCertificateValidatation(
HttpClientHelper.ConfigureCertificateValidation(
_options.ValidateCertificates,
out SecurityProtocolType protocolType,
out RemoteCertificateValidationCallback prevValidator);
@ -111,7 +111,7 @@ namespace Steeltoe.Security.Authentication.CloudFoundry
{
HttpRequestMessage requestMessage = GetTokenRequestMessage(ClientCredentialsTokenRequestParameters(), targetUrl);
HttpClientHelper.ConfigureCertificateValidatation(_options.ValidateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
HttpClientHelper.ConfigureCertificateValidation(_options.ValidateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
HttpResponseMessage response;
try

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

@ -124,7 +124,7 @@ namespace Steeltoe.Security.Authentication.CloudFoundry
HttpRequestMessage request = GetTokenInfoRequestMessage(tokens);
HttpClient client = GetHttpClient();
HttpClientHelper.ConfigureCertificateValidatation(
HttpClientHelper.ConfigureCertificateValidation(
Options.ValidateCertificates,
out SecurityProtocolType prevProtocols,
out RemoteCertificateValidationCallback prevValidator);

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

@ -84,7 +84,7 @@ namespace Steeltoe.Security.Authentication.CloudFoundry.Wcf
var requestMessage = new HttpRequestMessage(HttpMethod.Get, Options.AuthorizationUrl + CloudFoundryDefaults.JwtTokenUri);
requestMessage.Headers.Accept.Add(new MediaTypeWithQualityHeaderValue("application/json"));
HttpClientHelper.ConfigureCertificateValidatation(
HttpClientHelper.ConfigureCertificateValidation(
Options.ValidateCertificates,
out SecurityProtocolType protocolType,
out RemoteCertificateValidationCallback prevValidator);

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

@ -75,7 +75,7 @@ namespace Steeltoe.Security.DataProtection.CredHub
private async Task<CredHubClient> InitializeAsync(CredHubOptions options)
{
HttpClientHelper.ConfigureCertificateValidatation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
HttpClientHelper.ConfigureCertificateValidation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
try
{
Uri tokenUri;
@ -129,7 +129,7 @@ namespace Steeltoe.Security.DataProtection.CredHub
#pragma warning disable SA1202 // Elements must be ordered by access
public async Task<CredHubCredential<T>> WriteAsync<T>(CredentialSetRequest credentialRequest)
{
HttpClientHelper.ConfigureCertificateValidatation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
HttpClientHelper.ConfigureCertificateValidation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
try
{
_logger?.LogTrace($"About to PUT {_baseCredHubUrl}/v1/data");
@ -149,7 +149,7 @@ namespace Steeltoe.Security.DataProtection.CredHub
public async Task<CredHubCredential<T>> GenerateAsync<T>(CredHubGenerateRequest request)
{
HttpClientHelper.ConfigureCertificateValidatation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
HttpClientHelper.ConfigureCertificateValidation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
try
{
_logger?.LogTrace($"About to POST {_baseCredHubUrl}/v1/data");
@ -169,7 +169,7 @@ namespace Steeltoe.Security.DataProtection.CredHub
throw new ArgumentException("Name of credential to regenerate is required");
}
HttpClientHelper.ConfigureCertificateValidatation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
HttpClientHelper.ConfigureCertificateValidation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
try
{
_logger?.LogTrace($"About to POST {_baseCredHubUrl}/v1/data");
@ -189,7 +189,7 @@ namespace Steeltoe.Security.DataProtection.CredHub
throw new ArgumentException("Certificate authority used for certificates is required");
}
HttpClientHelper.ConfigureCertificateValidatation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
HttpClientHelper.ConfigureCertificateValidation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
try
{
_logger?.LogTrace($"About to POST {_baseCredHubUrl}/v1/bulk-regenerate");
@ -209,7 +209,7 @@ namespace Steeltoe.Security.DataProtection.CredHub
throw new ArgumentException("Id of credential is required");
}
HttpClientHelper.ConfigureCertificateValidatation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
HttpClientHelper.ConfigureCertificateValidation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
try
{
_logger?.LogTrace($"About to GET {_baseCredHubUrl}/v1/data{id}");
@ -229,7 +229,7 @@ namespace Steeltoe.Security.DataProtection.CredHub
throw new ArgumentException("Name of credential is required");
}
HttpClientHelper.ConfigureCertificateValidatation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
HttpClientHelper.ConfigureCertificateValidation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
try
{
_logger?.LogTrace($"About to GET {_baseCredHubUrl}/v1/data?name={name}&current=true");
@ -249,7 +249,7 @@ namespace Steeltoe.Security.DataProtection.CredHub
throw new ArgumentException("Name is required");
}
HttpClientHelper.ConfigureCertificateValidatation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
HttpClientHelper.ConfigureCertificateValidation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
try
{
_logger?.LogTrace($"About to GET {_baseCredHubUrl}/v1/data?name={name}&versions={entries}");
@ -269,7 +269,7 @@ namespace Steeltoe.Security.DataProtection.CredHub
throw new ArgumentException("Name is required");
}
HttpClientHelper.ConfigureCertificateValidatation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
HttpClientHelper.ConfigureCertificateValidation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
try
{
_logger?.LogTrace($"About to GET {_baseCredHubUrl}/v1/data?name-like={name}");
@ -289,7 +289,7 @@ namespace Steeltoe.Security.DataProtection.CredHub
throw new ArgumentException("Path is required");
}
HttpClientHelper.ConfigureCertificateValidatation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
HttpClientHelper.ConfigureCertificateValidation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
try
{
_logger?.LogTrace($"About to GET {_baseCredHubUrl}/v1/data?path={path}");
@ -304,7 +304,7 @@ namespace Steeltoe.Security.DataProtection.CredHub
public async Task<List<CredentialPath>> FindAllPathsAsync()
{
HttpClientHelper.ConfigureCertificateValidatation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
HttpClientHelper.ConfigureCertificateValidation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
try
{
_logger?.LogTrace($"About to GET {_baseCredHubUrl}/v1/data?paths=true");
@ -324,7 +324,7 @@ namespace Steeltoe.Security.DataProtection.CredHub
throw new ArgumentException("Name of credential to regenerate is required");
}
HttpClientHelper.ConfigureCertificateValidatation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
HttpClientHelper.ConfigureCertificateValidation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
try
{
_logger?.LogTrace($"About to DELETE {_baseCredHubUrl}/v1/data?name={name}");
@ -350,7 +350,7 @@ namespace Steeltoe.Security.DataProtection.CredHub
throw new ArgumentException("Name is required");
}
HttpClientHelper.ConfigureCertificateValidatation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
HttpClientHelper.ConfigureCertificateValidation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
try
{
_logger?.LogTrace($"About to GET {_baseCredHubUrl}/v1/permissions?credential_name={name}");
@ -375,7 +375,7 @@ namespace Steeltoe.Security.DataProtection.CredHub
throw new ArgumentException("At least one permission is required");
}
HttpClientHelper.ConfigureCertificateValidatation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
HttpClientHelper.ConfigureCertificateValidation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
try
{
_logger?.LogTrace($"About to POST {_baseCredHubUrl}/v1/permissions");
@ -402,7 +402,7 @@ namespace Steeltoe.Security.DataProtection.CredHub
throw new ArgumentException("Actor is required");
}
HttpClientHelper.ConfigureCertificateValidatation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
HttpClientHelper.ConfigureCertificateValidation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
try
{
_logger?.LogTrace($"About to DELETE {_baseCredHubUrl}/v1/permissions?credential_name={name}&actor={actor}");
@ -428,7 +428,7 @@ namespace Steeltoe.Security.DataProtection.CredHub
throw new ArgumentException("Service data is required");
}
HttpClientHelper.ConfigureCertificateValidatation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
HttpClientHelper.ConfigureCertificateValidation(_validateCertificates, out SecurityProtocolType protocolType, out RemoteCertificateValidationCallback prevValidator);
try
{
_logger?.LogTrace($"About to POST {_baseCredHubUrl}/v1/interpolate");