|
@@ -0,0 +1,28 @@
|
|
|
|
|
+From f9959d90deb34ddb0b86f91b51dee5ff50997de2 Mon Sep 17 00:00:00 2001
|
|
|
|
|
+From: Alexander Barton <alex@barton.de>
|
|
|
|
|
+Date: Sun, 17 Mar 2024 15:55:39 +0100
|
|
|
|
|
+Subject: [PATCH 20/20] METADATA: Fix unsetting "cloakhost"
|
|
|
|
|
+
|
|
|
|
|
+Correctly re-generate the "cloaked hostname" when removing the
|
|
|
|
|
+"cloakhost" using an empty string by passing down NULL instead of the
|
|
|
|
|
+empty string, which results in protocol violations (for example on
|
|
|
|
|
+WHOIS).
|
|
|
|
|
+
|
|
|
|
|
+(cherry picked from commit 1118b0e77ca961a7b082f90cb124210eca8fb6bd)
|
|
|
|
|
+---
|
|
|
|
|
+ src/ngircd/irc-metadata.c | 4 +++-
|
|
|
|
|
+ 1 file changed, 3 insertions(+), 1 deletion(-)
|
|
|
|
|
+
|
|
|
|
|
+--- a/src/ngircd/irc-metadata.c
|
|
|
|
|
++++ b/src/ngircd/irc-metadata.c
|
|
|
|
|
+@@ -72,7 +72,9 @@
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ if (strcasecmp(Req->argv[1], "cloakhost") == 0) {
|
|
|
|
|
+- Client_UpdateCloakedHostname(target, prefix, Req->argv[2]);
|
|
|
|
|
++ /* Set or remove a "cloaked hostname". */
|
|
|
|
|
++ Client_UpdateCloakedHostname(target, prefix,
|
|
|
|
|
++ *Req->argv[2] ? Req->argv[2] : NULL);
|
|
|
|
|
+ if (Client_Conn(target) > NONE && Client_HasMode(target, 'x'))
|
|
|
|
|
+ IRC_WriteStrClientPrefix(target, prefix,
|
|
|
|
|
+ RPL_HOSTHIDDEN_MSG, Client_ID(target),
|