mirror of
https://github.com/araxiaonline/WoW-Launcher.git
synced 2026-06-13 01:22:21 -04:00
Also print when a server is successfully validated.
This commit is contained in:
@@ -124,7 +124,14 @@ static class Launcher
|
||||
(object sender, X509Certificate certificate, X509Chain chain, SslPolicyErrors sslPolicyErrors) =>
|
||||
{
|
||||
if (sslPolicyErrors == SslPolicyErrors.None)
|
||||
{
|
||||
Console.ForegroundColor = ConsoleColor.Green;
|
||||
Console.WriteLine($"Certificate for server '{portal.HostName}' successfully validated.");
|
||||
Console.WriteLine();
|
||||
Console.ResetColor();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
// Redirect to the trusted cert warning.
|
||||
throw new AuthenticationException();
|
||||
@@ -132,7 +139,7 @@ static class Launcher
|
||||
null
|
||||
);
|
||||
|
||||
sslStream.AuthenticateAsClient("portal.HostName");
|
||||
sslStream.AuthenticateAsClient(portal.HostName);
|
||||
}
|
||||
catch (SocketException)
|
||||
{
|
||||
|
||||
@@ -68,7 +68,7 @@ static class Helpers
|
||||
var portalSpan = config.AsSpan(startQuoteIndex + 1, portalLength);
|
||||
var colonIndex = portalSpan.IndexOf(':');
|
||||
var ipSpan = colonIndex != -1 ? portalSpan[..colonIndex] : portalSpan;
|
||||
var port = colonIndex != -1 ? int.Parse(portalSpan[colonIndex..]) : 1119;
|
||||
var port = colonIndex != -1 ? int.Parse(portalSpan[(colonIndex + 1)..]) : 1119;
|
||||
var portalString = ipSpan.ToString().Trim();
|
||||
|
||||
try
|
||||
|
||||
Reference in New Issue
Block a user