Core/RemoteAccess: Added support for remote access using email/password.

This commit is contained in:
hondacrx
2021-03-15 14:04:47 -04:00
parent c521848465
commit ecad90c7d4
7 changed files with 364 additions and 2 deletions
+13
View File
@@ -18,6 +18,7 @@
using Framework.Configuration;
using Framework.Constants;
using Framework.Database;
using Framework.Networking;
using Game;
using Game.Chat;
using Game.Networking;
@@ -58,6 +59,18 @@ namespace WorldServer
Global.WorldMgr.SetInitialWorldSettings();
// Start the Remote Access port (acceptor) if enabled
if (ConfigMgr.GetDefaultValue("Ra.Enable", false))
{
int raPort = ConfigMgr.GetDefaultValue("Ra.Port", 3443);
string raListener = ConfigMgr.GetDefaultValue("Ra.IP", "0.0.0.0");
AsyncAcceptor raAcceptor = new();
if (!raAcceptor.Start(raListener, raPort))
Log.outError(LogFilter.Server, "Failed to initialize RemoteAccess Socket Server");
else
raAcceptor.AsyncAccept<RASocket>();
}
// Launch the worldserver listener socket
int worldPort = WorldConfig.GetIntValue(WorldCfg.PortWorld);
string worldListener = ConfigMgr.GetDefaultValue("BindIP", "0.0.0.0");
+29 -1
View File
@@ -2852,7 +2852,7 @@ Network.TcpNodelay = 1
###################################################################################################
###################################################################################################
# CONSOLE
# CONSOLE AND REMOTE ACCESS
#
# Console.Enable (NYI)
# Description: Enable console.
@@ -2861,6 +2861,34 @@ Network.TcpNodelay = 1
Console.Enable = 1
#
# Ra.Enable
# Description: Enable remote console (telnet).
# Default: 0 - (Disabled)
# 1 - (Enabled)
Ra.Enable = 0
#
# Ra.IP
# Description: Bind remote access to IP/hostname.
# Default: "0.0.0.0" - (Bind to all IPs on the system)
Ra.IP = "0.0.0.0"
#
# Ra.Port
# Description: TCP port to reach the remote console.
# Default: 3443
Ra.Port = 3443
#
# Ra.MinLevel
# Description: Required security level to use the remote console.
# Default: 3
Ra.MinLevel = 3
#
###################################################################################################
+1 -1
View File
@@ -5,7 +5,7 @@
<TargetFramework>net5.0</TargetFramework>
<ApplicationIcon>Blue.ico</ApplicationIcon>
<StartupObject>WorldServer.Server</StartupObject>
<LangVersion>8.0</LangVersion>
<LangVersion>9.0</LangVersion>
</PropertyGroup>
<ItemGroup>