-/* Overloaded function that has the option of using cidr */
-bool match(const char *str, const char *mask, bool use_cidr_match)
+// Below here is all wrappers around MatchInternal
+
+bool InspIRCd::Match(const std::string& str, const std::string& mask, unsigned const char* map)
+{
+ if (!map)
+ map = national_case_insensitive_map;
+
+ return MatchInternal((const unsigned char*)str.c_str(), (const unsigned char*)mask.c_str(), map);
+}
+
+bool InspIRCd::Match(const char* str, const char* mask, unsigned const char* map)
+{
+ if (!map)
+ map = national_case_insensitive_map;
+
+ return MatchInternal((const unsigned char*)str, (const unsigned char*)mask, map);
+}
+
+bool InspIRCd::MatchCIDR(const std::string& str, const std::string& mask, unsigned const char* map)
+{
+ if (irc::sockets::MatchCIDR(str, mask, true))
+ return true;
+
+ // Fall back to regular match
+ return InspIRCd::Match(str, mask, map);
+}
+
+bool InspIRCd::MatchCIDR(const char* str, const char* mask, unsigned const char* map)