clash_rules 0.1.13

a clash yaml rule parser and matching algorithms provider
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
This project can parse the rules in Clash’s YAML configuration files and provides an optimized matching algorithm.
The project uses functional programming.

DOMAIN-SUFFIX, IP-CIDR(6) uses radix trie ,DOMAIN-KEYWORD uses Aho-Corasick Automaton.

For examples, see the test at the end of the lib.rs and benches/algorithms.

There's a convenient struct `ClashRuleMatcher` and an enum `Rule`.

Also has feature to load and save to sqlite

supported rules are:
AND, OR, NOT, DOMAIN, DOMAIN-KEYWORD, DOMAIN-SUFFIX, DOMAIN-REGEX,
IP-CIDR, IP-CIDR6, GEOIP, PROCESS-NAME, NETWORK, DST-PORT, MATCH