全平台自动安装证书

This commit is contained in:
xljiulang 2021-07-18 02:49:17 +08:00
parent c5d31f38bf
commit e9439541c3
2 changed files with 21 additions and 24 deletions

View File

@ -63,8 +63,6 @@ namespace FastGithub
/// <param name="caPublicCerPath"></param>
/// <param name="logger"></param>
private static void TryInstallCaCert(string caPublicCerPath, ILogger logger)
{
if (OperatingSystem.IsWindows())
{
try
{
@ -83,6 +81,4 @@ namespace FastGithub
}
}
}
}
}

View File

@ -47,9 +47,9 @@ namespace FastGithub.ReverseProxy
error = ForwarderError.NoAvailableDestinations.ToString(),
message = $"不支持https反向代理{host}这个域名"
});
return;
}
else
{
var destinationPrefix = GetDestinationPrefix(host, domainConfig.Destination);
var requestConfig = new ForwarderRequestConfig { Timeout = domainConfig.Timeout };
@ -60,6 +60,7 @@ namespace FastGithub.ReverseProxy
var error = await httpForwarder.SendAsync(context, destinationPrefix, httpClient, requestConfig);
await ResponseErrorAsync(context, error);
}
}
/// <summary>
/// 获取目标前缀