oper doing some lccal gline/jupe action on a remote server never gets a reply in case of succes this patch sends a copy of the snomask message shown to local opers to the remote source oper diff -r 032bd91a5810 ircd/gline.c --- a/ircd/gline.c +++ b/ircd/gline.c @@ -595,6 +595,18 @@ flags & (GLINE_BADCHAN|GLINE_REALNAME) ? "" : host, expire, reason); + /* local gline set by remote user, inform oper of success */ + if ((flags & GLINE_LOCAL) && IsUser(sptr) && !MyConnect(sptr)) + sendcmdto_one(&me, CMD_NOTICE, sptr, "%C :%s adding local %s for %s%s%s%s%s, expiring at %Tu: %s", + sptr, cli_name(sptr), + (flags & GLINE_BADCHAN) ? "BADCHAN" : "GLINE", + (flags & (GLINE_BADCHAN|GLINE_REALNAME)) ? "" : nick, + (flags & (GLINE_BADCHAN|GLINE_REALNAME)) ? "" : "!", + user, + (flags & (GLINE_BADCHAN|GLINE_REALNAME)) ? "" : "@", + (flags & (GLINE_BADCHAN|GLINE_REALNAME)) ? "" : host, + expire + TSoffset, reason); + /* make the gline */ agline = make_gline(nick, user, host, reason, expire, lastmod, lifetime, flags); @@ -937,6 +949,16 @@ gline->gl_host ? "@" : "", gline->gl_host ? gline->gl_host : "", buf); + /* local change by remote user, inform oper of success */ + if ((action == GLINE_LOCAL_ACTIVATE || action == GLINE_LOCAL_DEACTIVATE) && IsUser(sptr) && !MyConnect(sptr)) + sendcmdto_one(&me, CMD_NOTICE, sptr, "%C :%s modifying global %s for %s%s%s%s%s:%s", + sptr, cli_name(sptr), + GlineIsBadChan(gline) ? "BADCHAN" : "GLINE", + GlineIsBadChan(gline)|GlineIsRealName(gline) ? "" : gline->gl_nick, + GlineIsBadChan(gline)|GlineIsRealName(gline) ? "" : "!", + gline->gl_user, gline->gl_host ? "@" : "", + gline->gl_host ? gline->gl_host : "", buf); + /* We'll be simple for this release, but we can update this to change * the propagation syntax on future updates */ @@ -984,6 +1006,16 @@ gline->gl_user, gline->gl_host ? "@" : "", gline->gl_host ? gline->gl_host : ""); + /* local change by remote user, inform oper of success */ + if (IsUser(sptr) && !MyConnect(sptr)) + sendcmdto_one(&me, CMD_NOTICE, sptr, "%C :%s removing local %s for %s%s%s%s%s", + sptr, cli_name(sptr), + GlineIsBadChan(gline) ? "BADCHAN" : "GLINE", + GlineIsBadChan(gline)|GlineIsRealName(gline) ? "" : gline->gl_nick, + GlineIsBadChan(gline)|GlineIsRealName(gline) ? "" : "!", + gline->gl_user, gline->gl_host ? "@" : "", + gline->gl_host ? gline->gl_host : ""); + gline_free(gline); /* get rid of the G-line */ return 0; /* convenience return */ diff -r 032bd91a5810 ircd/jupe.c --- a/ircd/jupe.c +++ b/ircd/jupe.c @@ -166,6 +166,20 @@ flags & JUPE_LOCAL ? "local " : "", server, expire + TSoffset, reason); + /* local jupe - let's see who else to inform */ + if (flags & JUPE_LOCAL) { + + /* set by remote oper - inform them about the success */ + if (IsUser(sptr) && !MyConnect(sptr)) + sendcmdto_one(&me, CMD_NOTICE, sptr, "%C :%s adding local JUPE for %s, expiring at %Tu: %s", + sptr, cli_name(sptr), server, expire + TSoffset, reason); + + /* set by remote oper or a server/service - inform all opers */ + if (!MyUser(sptr)) + sendwallto_group_butone(&me, WALL_WALLOPS, 0, "%s adding local JUPE for %s, expiring at %Tu: %s", + cli_name(sptr), server, expire + TSoffset, reason); + } + /* make the jupe */ ajupe = make_jupe(server, reason, expire, lastmod, flags); @@ -275,6 +289,22 @@ JupeIsLocal(jupe) ? "removing local" : "deactivating", jupe->ju_server, jupe->ju_expire + TSoffset, jupe->ju_reason); + /* local jupe - let's see who else to inform */ + if (flags & JUPE_LOCAL) { + + /* done by remote oper - inform them about the success */ + if (IsUser(sptr) && !MyConnect(sptr)) + sendcmdto_one(&me, CMD_NOTICE, sptr, "%C :% %s JUPE for %s, expiring at %Tu: %s", + sptr, cli_name(sptr), JupeIsLocal(jupe) ? "removing local" : "locally deactivating", + jupe->ju_server, jupe->ju_expire + TSoffset, jupe->ju_reason); + + /* done by remote oper or a server/service - inform all opers */ + if (!MyUser(sptr)) + sendwallto_group_butone(&me, WALL_WALLOPS, 0, "%s %s JUPE for %s, expiring at %Tu: %s", + cli_name(sptr), JupeIsLocal(jupe) ? "removing local" : "locally deactivating", + jupe->ju_server, jupe->ju_expire + TSoffset, jupe->ju_reason); + } + if (JupeIsLocal(jupe)) jupe_free(jupe); else if (!(flags & JUPE_LOCAL)) /* don't propagate local changes */