+
+ while ((wild != mask.end()) && (*wild == '*'))
+ wild++;
+
+ return wild == mask.end();
+}
+
+/* Overloaded function that has the option of using cidr */
+CoreExport bool match(const std::string &str, const std::string &mask, bool use_cidr_match)
+{
+ if (use_cidr_match && MatchCIDR(str, mask, true))
+ return true;
+ return match(str, mask);
+}
+
+CoreExport bool match(bool case_sensitive, const std::string &str, const std::string &mask, bool use_cidr_match)
+{
+ if (use_cidr_match && MatchCIDR(str, mask, true))
+ return true;
+
+ return case_sensitive ? csmatch(str, mask) : match(str, mask);
+}
+
+CoreExport bool match(bool case_sensitive, const std::string &str, const std::string &mask)
+{
+ return case_sensitive ? csmatch(str, mask) : match(str, mask);