Logical Combination Rule
Chute supports logical combination rules: AND, OR, and NOT. These rules can combine multiple sub-rules to create complex matching conditions.
AND
Rule matches only when all sub-rules match.
Syntax: AND,((SUB-RULE),(SUB-RULE),...),POLICY
AND,((DOMAIN,example.com),(DEST-PORT,443)),Proxy
AND,((DOMAIN-SUFFIX,google.com),(GEOIP,US,no-resolve)),DIRECT
Each sub-rule uses the same TYPE,VALUE syntax as a regular rule, but without the policy.
OR
Rule matches when any sub-rule matches.
Syntax: OR,((SUB-RULE),(SUB-RULE),...),POLICY
OR,((DOMAIN,example.com),(DOMAIN,test.com)),Proxy
OR,((DOMAIN-SUFFIX,apple.com),(DOMAIN-SUFFIX,icloud.com)),DIRECT
NOT
Rule matches when the sub-rule does NOT match.
Syntax: NOT,((SUB-RULE)),POLICY
NOT,((DOMAIN,example.com)),Proxy
NOT,((RULE-SET,SYSTEM)),Proxy
Note: The sub-rules are enclosed in double parentheses
((...)).