Sfoglia il codice sorgente

Merge branch 'protect-telnet-user-match' into next

* protect-telnet-user-match:
  Enable host-user matching for bot links

Conflicts:
	doc/UPDATES
Bryan Drewery 13 anni fa
parent
commit
1f890ee49d
2 ha cambiato i file con 5 aggiunte e 3 eliminazioni
  1. 2 0
      doc/UPDATES
  2. 3 3
      src/dcc.c

+ 2 - 0
doc/UPDATES

@@ -2,6 +2,8 @@ next
   * Bot will now jump from the server it's on if it is removed from the server list. (fixes a changing network bug)
   * Properly honor exemptions when kicking matched RBL clients
   * Fix LASTON not being shared
+  * Bots linking in must now have a matching host on their user to succeed linking.
+    This was always requiring a valid host, but was not restricted to that bot.
 
 maint
   * Default 'set promisc' to ignore since it's usually a false positive

+ 3 - 3
src/dcc.c

@@ -1814,9 +1814,9 @@ dcc_telnet_id(int idx, char *buf, int atr)
     if (!u)
       ok = 0;
 
-//    // Restrict connect to matching the user who they claim to be
-//    if (u && strcasecmp(nick, u->handle))
-//      ok = 0;
+    // Restrict connect to matching the user who they claim to be
+    if (u && strcasecmp(nick, u->handle))
+      ok = 0;
 
     if (!ok) {
       putlog(LOG_BOTS, "*", "Denied link to '%s': Host not recognized: %s", nick, dcc[idx].host);