summaryrefslogtreecommitdiff
path: root/src/elogin
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-07-05 01:57:52 +0300
committerAndrei Karas <akaras@inbox.ru>2015-07-05 01:57:52 +0300
commit7eaba97f02e18d8610ea004851ab2ec8b8edeebb (patch)
tree12bf9a8e1cd1b2e5813bb8985b70febf463dfc53 /src/elogin
parentebff0ef78313b1090b2efa3a8d64d5493a9a5aed (diff)
downloadevol-hercules-7eaba97f02e18d8610ea004851ab2ec8b8edeebb.tar.gz
evol-hercules-7eaba97f02e18d8610ea004851ab2ec8b8edeebb.tar.bz2
evol-hercules-7eaba97f02e18d8610ea004851ab2ec8b8edeebb.tar.xz
evol-hercules-7eaba97f02e18d8610ea004851ab2ec8b8edeebb.zip
Remove inter server ip check because it moving to upstream.
Diffstat (limited to 'src/elogin')
-rw-r--r--src/elogin/config.c16
-rw-r--r--src/elogin/config.h2
-rw-r--r--src/elogin/init.c2
-rw-r--r--src/elogin/parse.c13
-rw-r--r--src/elogin/parse.h1
5 files changed, 0 insertions, 34 deletions
diff --git a/src/elogin/config.c b/src/elogin/config.c
index 83c3c4f..6abaa6c 100644
--- a/src/elogin/config.c
+++ b/src/elogin/config.c
@@ -14,30 +14,14 @@
#include "elogin/config.h"
char *update_server = NULL;
-char *inter_server_ip = NULL;
void config_update_server(const char *val)
{
update_server = aStrdup(val);
}
-void config_inter_server_ip(const char *val)
-{
- char buf[1000];
-
- if (strlen(val) > 900)
- return;
-
- strcpy(buf, ",");
- strcat(buf, val);
- strcat(buf, ",");
- inter_server_ip = aStrdup(buf);
-}
-
void config_final(void)
{
if (update_server)
aFree(update_server);
- if (inter_server_ip)
- aFree(inter_server_ip);
}
diff --git a/src/elogin/config.h b/src/elogin/config.h
index ad63371..a491e1e 100644
--- a/src/elogin/config.h
+++ b/src/elogin/config.h
@@ -6,9 +6,7 @@
void config_update_server(const char *val);
void config_final(void);
-void config_inter_server_ip(const char *val);
extern char *update_server;
-extern char *inter_server_ip;
#endif // EVOL_LOGIN_CONFIG
diff --git a/src/elogin/init.c b/src/elogin/init.c
index 6105b3b..e0411bd 100644
--- a/src/elogin/init.c
+++ b/src/elogin/init.c
@@ -37,7 +37,6 @@ HPExport void plugin_init (void)
addPacket(0x027c, 95, elogin_parse_client_login2, hpParse_Login);
addPacket(0x5000, 54, elogin_parse_change_paassword, hpParse_FromChar);
addHookPre("login->parse_client_login", elogin_parse_client_login_pre);
- addHookPre("login->parse_request_connection", elogin_parse_request_connection);
addHookPre("login->check_password", elogin_check_password);
addHookPre("login->parse_ping", elogin_parse_ping);
}
@@ -46,7 +45,6 @@ HPExport void server_preinit (void)
{
iMalloc = GET_SYMBOL("iMalloc");
addLoginConf("update_server", config_update_server);
- addLoginConf("inter_server_ip", config_inter_server_ip);
}
HPExport void server_online (void)
diff --git a/src/elogin/parse.c b/src/elogin/parse.c
index 8f62e9f..3a015d1 100644
--- a/src/elogin/parse.c
+++ b/src/elogin/parse.c
@@ -14,7 +14,6 @@
#include "login/account.h"
#include "login/login.h"
-#include "ecommon/ip.h"
#include "elogin/config.h"
#include "elogin/md5calc.h"
#include "elogin/parse.h"
@@ -141,18 +140,6 @@ void elogin_parse_client_login2(int fd)
return;
}
-void elogin_parse_request_connection(int *fd, struct login_session_data* sd, const char *const ip)
-{
- if (!inter_server_ip || !ip)
- return;
- if (!checkAllowedIp(inter_server_ip, ip))
- {
- hookStop();
- login->char_server_connection_status(*fd, sd, 3);
- ShowNotice("Connection of the char-server from ip %s REFUSED.\n", ip);
- }
-}
-
void elogin_parse_ping(int *fd, struct login_session_data* sd)
{
RFIFOSKIP(*fd, 26);
diff --git a/src/elogin/parse.h b/src/elogin/parse.h
index b5c2418..ad76331 100644
--- a/src/elogin/parse.h
+++ b/src/elogin/parse.h
@@ -7,7 +7,6 @@
void login_parse_version(int fd);
int elogin_parse_client_login_pre(int *fd, struct login_session_data* sd, const char *const ip);
void elogin_parse_client_login2(int fd);
-void elogin_parse_request_connection(int *fd, struct login_session_data* sd, const char *const ip);
void elogin_parse_ping(int *fd, struct login_session_data* sd);
void elogin_parse_change_paassword(int fd);