diff options
author | Haru <haru@dotalux.com> | 2016-02-11 00:41:54 +0100 |
---|---|---|
committer | Haru <haru@dotalux.com> | 2016-08-19 21:32:15 +0200 |
commit | f56264d23d9cc86a87331401496e206639cdd6e3 (patch) | |
tree | 57891c2901c8cdc114baf4fbfa4dd927b5a87204 /src/login/login.h | |
parent | 3c84a4df688a63577236d02b4d972775964f71ca (diff) | |
download | hercules-f56264d23d9cc86a87331401496e206639cdd6e3.tar.gz hercules-f56264d23d9cc86a87331401496e206639cdd6e3.tar.bz2 hercules-f56264d23d9cc86a87331401496e206639cdd6e3.tar.xz hercules-f56264d23d9cc86a87331401496e206639cdd6e3.zip |
Ported login-server.conf to libconfig
Ported to modern Hercules and cleaned up from Panikon's commits: ceb8a486ac47c2ed9aae4baa1ec39a11f31e9368, c1049123a4ea6ae6f0992ffe766db8aed7435ab5, 6feb097046355610d2288670a569ccc175358580, 9f6e27a96d655f2b4555310786d9d10898754404, 21fa5d24255ba026f96b1dbedf74ac5ef831d3ae, e22a56ad4def8ca22e94d44377a5364b9db1a425, f753a754923140bfec02057c16e6e8429b863d0e, 25dde7e46524ace330b83cb4bf0255cc4d796792
Signed-off-by: Haru <haru@dotalux.com>
Diffstat (limited to 'src/login/login.h')
-rw-r--r-- | src/login/login.h | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/src/login/login.h b/src/login/login.h index 36085ae91..5632e6529 100644 --- a/src/login/login.h +++ b/src/login/login.h @@ -97,8 +97,8 @@ struct Login_Config { uint32 login_ip; ///< the address to bind to uint16 login_port; ///< the port to bind to - unsigned int ipban_cleanup_interval; ///< interval (in seconds) to clean up expired IP bans - unsigned int ip_sync_interval; ///< interval (in minutes) to execute a DNS/IP update (for dynamic IPs) + uint32 ipban_cleanup_interval; ///< interval (in seconds) to clean up expired IP bans + uint32 ip_sync_interval; ///< interval (in minutes) to execute a DNS/IP update (for dynamic IPs) bool log_login; ///< whether to log login server actions or not char date_format[32]; ///< date format used in messages bool new_account_flag,new_acc_length_limit; ///< auto-registration via _M/_F ? / if yes minimum length is 4? @@ -113,13 +113,14 @@ struct Login_Config { bool ipban; ///< perform IP blocking (via contents of `ipbanlist`) ? bool dynamic_pass_failure_ban; ///< automatic IP blocking due to failed login attemps ? - unsigned int dynamic_pass_failure_ban_interval; ///< how far to scan the loginlog for password failures - unsigned int dynamic_pass_failure_ban_limit; ///< number of failures needed to trigger the ipban - unsigned int dynamic_pass_failure_ban_duration; ///< duration of the ipban + uint32 dynamic_pass_failure_ban_interval; ///< how far to scan the loginlog for password failures + uint32 dynamic_pass_failure_ban_limit; ///< number of failures needed to trigger the ipban + uint32 dynamic_pass_failure_ban_duration; ///< duration of the ipban bool use_dnsbl; ///< dns blacklist blocking ? - char dnsbl_servs[1024]; ///< comma-separated list of dnsbl servers + VECTOR_DECL(char *) dnsbl_servers; ///< dnsbl servers - int client_hash_check; ///< flags for checking client md5 + bool client_hash_check; ///< flags for checking client md5 + // TODO: VECTOR candidate struct client_hash_node *client_hash_nodes; ///< linked list containg md5 hash for each gm group }; @@ -207,7 +208,7 @@ struct login_interface { void (*char_server_connection_status) (int fd, struct login_session_data* sd, uint8 status); void (*parse_request_connection) (int fd, struct login_session_data* sd, const char *ip, uint32 ipl); void (*config_set_defaults) (void); - int (*config_read) (const char *cfgName); + bool (*config_read) (const char *filename, bool included); char *LOGIN_CONF_NAME; char *NET_CONF_NAME; ///< Network configuration filename }; |