Update of /cvsroot/srvx/services/src
In directory sc8-pr-cvs1:/tmp/cvs-serv1354/src
Modified Files:
opserv.c
Log Message:
complain if somebody tries to addtrust *@host
Index: opserv.c
===================================================================
RCS file: /cvsroot/srvx/services/src/opserv.c,v
retrieving revision 1.291
retrieving revision 1.292
diff -C2 -r1.291 -r1.292
*** opserv.c 14 Nov 2002 02:22:35 -0000 1.291
--- opserv.c 22 Nov 2002 04:11:24 -0000 1.292
***************
*** 134,137 ****
--- 134,138 ----
#define OSMSG_NOT_EXEMPT "$b%s$b is not on the exempt list."
#define OSMSG_ALREADY_TRUSTED "Host $b%s$b is already trusted (use $bdeltrust$b and then $baddtrust$b to adjust)."
+ #define OSMSG_HOSTNAME_ONLY "Please only use the hostname, and no ident part."
#define OSMSG_ADDED_TRUSTED "Added trusted hosts to the trusted-hosts list."
#define OSMSG_REMOVED_TRUSTED "Removed trusted hosts from the trusted-hosts list."
***************
*** 2101,2104 ****
--- 2102,2109 ----
if (dict_find(opserv_trusted_hosts, argv[1], NULL)) {
return opserv_notice(user, OSMSG_ALREADY_TRUSTED, argv[1]);
+ }
+ if (strchr(argv[1], '@')) {
+ reply(OSMSG_HOSTNAME_ONLY);
+ return 0;
}
reason = unsplit_string(argv+4, argc-4, NULL);
|