diff options
author | Luke Bratch <luke@bratch.co.uk> | 2019-05-27 22:05:20 +0100 |
---|---|---|
committer | Luke Bratch <luke@bratch.co.uk> | 2019-05-27 22:05:20 +0100 |
commit | 4b2cd5c4c349ea3e5683a6b2beb42c518d3ccef3 (patch) | |
tree | fc3ca902e3ce6027a205a6e3b5cc3c9030fcd9d0 | |
parent | 871184560b17553e84cc711a487ddf928671c56c (diff) |
Include 671 (RPL_WHOISSECURE) responses in WHOIS pending code.
-rw-r--r-- | TODO | 2 | ||||
-rw-r--r-- | blabouncer.c | 9 |
2 files changed, 5 insertions, 6 deletions
@@ -10,5 +10,3 @@ Add various auto replay options: Might need to #include <limits.h> in blabouncer.c to make some operating systems and/or compilers happy. Send a PING to the server before assuming a timeout is definite. - -Include server 671 responses in WHO pending code. diff --git a/blabouncer.c b/blabouncer.c index 6149ef1..85305c6 100644 --- a/blabouncer.c +++ b/blabouncer.c @@ -1292,15 +1292,16 @@ int processircmessage(SSL *server_ssl, char *str, int source, struct client *cli } // Server 307 (RPL_SUSERHOST), 311 (RPL_WHOISUSER), 312 (RPL_WHOISSERVER), 313 (RPL_WHOISOPERATOR), 317 (RPL_WHOISIDLE), - // 319 (RPL_WHOISCHANNELS), 320 (RPL_WHOISSPECIAL), or 318 (RPL_ENDOFWHOIS) received? + // 319 (RPL_WHOISCHANNELS), 320 (RPL_WHOISSPECIAL), 671 (RPL_WHOISSECURE), or 318 (RPL_ENDOFWHOIS) received? // Send to any clients who requested a WHOIS. if (strncmp(tokens[1], "307", strlen(tokens[1])) == 0 || strncmp(tokens[1], "311", strlen(tokens[1])) == 0 || strncmp(tokens[1], "312", strlen(tokens[1])) == 0 || strncmp(tokens[1], "313", strlen(tokens[1])) == 0 || strncmp(tokens[1], "317", strlen(tokens[1])) == 0 || strncmp(tokens[1], "319", strlen(tokens[1])) == 0 || - strncmp(tokens[1], "320", strlen(tokens[1])) == 0 || strncmp(tokens[1], "318", strlen(tokens[1])) == 0) { + strncmp(tokens[1], "320", strlen(tokens[1])) == 0 || strncmp(tokens[1], "671", strlen(tokens[1])) == 0 || + strncmp(tokens[1], "318", strlen(tokens[1])) == 0) { printf("Server 307 RPL_SUSERHOST, 311 RPL_WHOISUSER, 312 RPL_WHOISSERVER, 313 (RPL_WHOISOPERATOR), 317 RPL_WHOISIDLE, " - "319 RPL_WHOISCHANNELS, 320 (RPL_WHOISSPECIAL), or 318 RPL_ENDOFWHOIS found and it is: %s with length %zd! " - "Sending to clients who are pending one of these.\n", tokens[1], strlen(tokens[1])); + "319 RPL_WHOISCHANNELS, 320 (RPL_WHOISSPECIAL), 671 (RPL_WHOISSECURE), or 318 RPL_ENDOFWHOIS found and it is: " + "%s with length %zd! Sending to clients who are pending one of these.\n", tokens[1], strlen(tokens[1])); // Relay to all pending clients for (int i = 0; i < MAXCLIENTS; i++) { |