X-Git-Url: https://jfr.im/git/solanum.git/blobdiff_plain/2f355b7e3cafdef3a614b723cc2a6c70a1d8339e..f8838806ef332738fd17e725c9e7d5b1418a9756:/modules/m_trace.c diff --git a/modules/m_trace.c b/modules/m_trace.c index 38550667..a634635b 100644 --- a/modules/m_trace.c +++ b/modules/m_trace.c @@ -125,7 +125,7 @@ m_trace(struct MsgBuf *msgbuf_p, struct Client *client_p, struct Client *source_ /* giving this out with flattened links defeats the * object --fl */ - if(IsOper(source_p) || IsExemptShide(source_p) || + if(IsOperGeneral(source_p) || IsExemptShide(source_p) || !ConfigServerHide.flatten_links) sendto_one_numeric(source_p, RPL_TRACELINK, form_str(RPL_TRACELINK), @@ -204,6 +204,9 @@ m_trace(struct MsgBuf *msgbuf_p, struct Client *client_p, struct Client *source_ if(!doall && wilds && (match(tname, target_p->name) == 0)) continue; + if(!SeesOper(target_p, source_p)) + continue; + report_this_status(source_p, target_p); } @@ -233,14 +236,14 @@ m_trace(struct MsgBuf *msgbuf_p, struct Client *client_p, struct Client *source_ target_p = ptr->data; /* dont show invisible users to remote opers */ - if(IsInvisible(target_p) && dow && !MyConnect(source_p) && !IsOper(target_p)) + if(IsInvisible(target_p) && dow && !MyConnect(source_p) && !SeesOper(target_p, source_p)) continue; if(!doall && wilds && !match(tname, target_p->name)) continue; /* remote opers may not see invisible normal users */ - if(dow && !MyConnect(source_p) && !IsOper(target_p) && + if(dow && !MyConnect(source_p) && !SeesOper(target_p, source_p) && IsInvisible(target_p)) continue; @@ -379,8 +382,8 @@ report_this_status(struct Client *source_p, struct Client *target_p) case STAT_CLIENT: { sendto_one_numeric(source_p, - IsOper(target_p) ? RPL_TRACEOPERATOR : RPL_TRACEUSER, - IsOper(target_p) ? form_str(RPL_TRACEOPERATOR) : form_str(RPL_TRACEUSER), + SeesOper(target_p, source_p) ? RPL_TRACEOPERATOR : RPL_TRACEUSER, + SeesOper(target_p, source_p) ? form_str(RPL_TRACEOPERATOR) : form_str(RPL_TRACEUSER), class_name, name, show_ip(source_p, target_p) ? ip : empty_sockhost, (unsigned long)(rb_current_time() - target_p->localClient->lasttime),