From e9ced3de2078ef9d012228d2f27f80334f2870d9 Mon Sep 17 00:00:00 2001 From: Jilles Tjoelker Date: Sat, 8 Jan 2011 17:47:05 +0100 Subject: [PATCH] hunt_server: Disallow wildcarded nicknames. Any hunted parameter with wildcards is now assumed to be a server, never a user. Reasons: * fewer match() calls * do not disclose existing nicknames * more intuitive behaviour for CONNECT m_trace has a copy of some hunt_server logic in it (for the RPL_TRACELINK reply), so adjust that too. --- modules/m_trace.c | 2 +- src/s_serv.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/m_trace.c b/modules/m_trace.c index e2c0e0b..0482c1d 100644 --- a/modules/m_trace.c +++ b/modules/m_trace.c @@ -110,7 +110,7 @@ m_trace(struct Client *client_p, struct Client *source_p, int parc, const char * if(ac2ptr == NULL) { - RB_DLINK_FOREACH(ptr, global_client_list.head) + RB_DLINK_FOREACH(ptr, global_serv_list.head) { ac2ptr = ptr->data; diff --git a/src/s_serv.c b/src/s_serv.c index 79a318c..161dc81 100644 --- a/src/s_serv.c +++ b/src/s_serv.c @@ -157,7 +157,7 @@ hunt_server(struct Client *client_p, struct Client *source_p, */ if(!target_p && wilds) { - RB_DLINK_FOREACH(ptr, global_client_list.head) + RB_DLINK_FOREACH(ptr, global_serv_list.head) { if(match(new, ((struct Client *) (ptr->data))->name)) {