Update of /cvsroot/srvx/services/src
In directory usw-pr-cvs1:/tmp/cvs-serv5116/src
Modified Files:
nickserv.c
Log Message:
implement a shameless knockoff of Quakenet Q's extra login warning
Index: nickserv.c
===================================================================
RCS file: /cvsroot/srvx/services/src/nickserv.c,v
retrieving revision 1.204
retrieving revision 1.205
diff -C2 -r1.204 -r1.205
*** nickserv.c 11 Sep 2002 02:01:01 -0000 1.204
--- nickserv.c 14 Sep 2002 03:49:33 -0000 1.205
***************
*** 213,216 ****
--- 213,217 ----
#define NSMSG_RECLAIMED_SVSNICK "Forcibly changed %s's nick."
#define NSMSG_RECLAIMED_KILL "Disconnected %s from the network."
+ #define NSMSG_CLONE_AUTH "Warning: %s (%s@%s) authed to your account."
#define NSMSG_SETTING_LIST "$b$N account settings:$b"
***************
*** 270,273 ****
--- 271,275 ----
unsigned int default_hostmask : 1;
unsigned int warn_nick_owned : 1;
+ unsigned int warn_clone_auth : 1;
unsigned long nicks_per_handle;
unsigned long password_min_length;
***************
*** 769,772 ****
--- 771,780 ----
HANDLE_CLEAR_FLAG(hi, FROZEN);
snprintf(hi->last_authed_host, sizeof(hi->last_authed_host), "%s@%s", user->ident, user->hostname);
+ if (nickserv_conf.warn_clone_auth) {
+ struct userNode *other;
+ for (other = hi->users; other; other = other->next_authed) {
+ nickserv_notice(other, NSMSG_CLONE_AUTH, user->nick, user->ident, user->hostname);
+ }
+ }
user->next_authed = hi->users;
hi->users = user;
***************
*** 2969,2972 ****
--- 2977,2982 ----
if (!str) str = database_get_data(conf_node, KEY_NOCHAN_ACCOUNT_EXPIRE_DELAY, RECDB_QSTRING);
nickserv_conf.nochan_handle_expire_delay = str ? ParseInterval(str) : 86400*15;
+ str = database_get_data(conf_node, "warn_clone_auth", RECDB_QSTRING);
+ nickserv_conf.warn_clone_auth = str ? !disabled_string(str) : 1;
if (!nickserv_conf.disable_nicks) {
str = database_get_data(conf_node, "reclaim_action", RECDB_QSTRING);
|