From aaceb4fd9aae237a27b1b88d8b23432e02dcfa42 Mon Sep 17 00:00:00 2001 From: Sadie Powell Date: Tue, 20 Jan 2026 20:59:33 +0000 Subject: Check the length of the username in DefaultIsUser. --- src/helperfuncs.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/helperfuncs.cpp') diff --git a/src/helperfuncs.cpp b/src/helperfuncs.cpp index 756aeb11b..ac6e9fccc 100644 --- a/src/helperfuncs.cpp +++ b/src/helperfuncs.cpp @@ -277,7 +277,7 @@ bool InspIRCd::DefaultIsNick(const std::string_view& n) /* return true for good username, false else */ bool InspIRCd::DefaultIsUser(const std::string_view& n) { - if (n.empty()) + if (n.empty() || n.length() > ServerInstance->Config->Limits.MaxUser) return false; for (const auto chr : n) -- cgit v1.3.1-10-gc9f91