From 80e80132826569444e690a177f5bfc5f603fada1 Mon Sep 17 00:00:00 2001 From: Sadie Powell Date: Sun, 17 Apr 2022 11:02:42 +0100 Subject: Remove ValidateParam and rename CanonicalizeParam. There's basically no safe way to handle a malformed list mode sent by a remote server without causing a desync. Its probably for the best if we just only apply validation to locally added list modes entries. --- src/modules/m_exemptchanops.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/modules/m_exemptchanops.cpp') diff --git a/src/modules/m_exemptchanops.cpp b/src/modules/m_exemptchanops.cpp index 89c1688fc..c384e723f 100644 --- a/src/modules/m_exemptchanops.cpp +++ b/src/modules/m_exemptchanops.cpp @@ -81,8 +81,9 @@ public: return MOD_RES_DENY; } - bool ValidateParam(User* user, Channel* chan, const std::string& parameter) override + bool ValidateParam(LocalUser* user, Channel* chan, std::string& parameter) override { + // We only enforce the format restriction against local users to avoid causing a desync. std::string restriction; std::string prefix; if (!ParseEntry(parameter, restriction, prefix)) -- cgit v1.3.1-10-gc9f91