Allow NO_SSL_VERIFY in RawHttpMessageHandler. (#3883)

This commit is contained in:
Tingluo Huang
2025-05-30 22:48:16 -04:00
committed by GitHub
parent f03fcc8a01
commit acf3f2ba12
2 changed files with 14 additions and 0 deletions

View File

@@ -38,6 +38,7 @@ namespace GitHub.Runner.Sdk
if (StringUtil.ConvertToBoolean(Environment.GetEnvironmentVariable("GITHUB_ACTIONS_RUNNER_TLS_NO_VERIFY")))
{
VssClientHttpRequestSettings.Default.ServerCertificateValidationCallback = HttpClientHandler.DangerousAcceptAnyServerCertificateValidator;
RawClientHttpRequestSettings.Default.ServerCertificateValidationCallback = HttpClientHandler.DangerousAcceptAnyServerCertificateValidator;
}
var rawHeaderValues = new List<ProductInfoHeaderValue>();