调整WAF操作符顺序

This commit is contained in:
刘祥超
2023-01-07 09:35:09 +08:00
parent 16e418447a
commit d3c8d8fd04

View File

@@ -125,18 +125,6 @@ var AllRuleOperators = []*RuleOperatorDefinition{
Description: "不包含某个字符串比如Hello字符串中不包含Hi",
CaseInsensitive: HTTPFirewallRuleCaseInsensitiveNo,
},
{
Name: "包含前缀",
Code: HTTPFirewallRuleOperatorPrefix,
Description: "包含字符串前缀部分,比如/hello前缀会匹配/hello, /hello/world等",
CaseInsensitive: HTTPFirewallRuleCaseInsensitiveNo,
},
{
Name: "包含后缀",
Code: HTTPFirewallRuleOperatorSuffix,
Description: "包含字符串后缀部分,比如/hello后缀会匹配/hello, /hi/hello等",
CaseInsensitive: HTTPFirewallRuleCaseInsensitiveNo,
},
{
Name: "包含任一字符串",
Code: HTTPFirewallRuleOperatorContainsAny,
@@ -149,6 +137,18 @@ var AllRuleOperators = []*RuleOperatorDefinition{
Description: "包含字符串列表中的所有字符串,比如/hello/world必须包含/hello和/world每行一个字符串",
CaseInsensitive: HTTPFirewallRuleCaseInsensitiveNo,
},
{
Name: "包含前缀",
Code: HTTPFirewallRuleOperatorPrefix,
Description: "包含字符串前缀部分,比如/hello前缀会匹配/hello, /hello/world等",
CaseInsensitive: HTTPFirewallRuleCaseInsensitiveNo,
},
{
Name: "包含后缀",
Code: HTTPFirewallRuleOperatorSuffix,
Description: "包含字符串后缀部分,比如/hello后缀会匹配/hello, /hi/hello等",
CaseInsensitive: HTTPFirewallRuleCaseInsensitiveNo,
},
{
Name: "包含二进制数据",
Code: HTTPFirewallRuleOperatorContainsBinary,