Debian Codegraph @

test/functional/configs/fuzzy_html_test.conf

raw
1 # Test configuration for HTML fuzzy hashing
2
3 .include(duplicate=append,priority=0) "{= env.TESTDIR =}/configs/plugins.conf"
4 .include(duplicate=merge,priority=0) "{= env.TESTDIR =}/configs/statistic.conf"
5
6 fuzzy_check {
7 # Test rule for HTML fuzzy hashing
8 rule "TEST_HTML_FUZZY" {
9 servers = "localhost:11335";
10 algorithm = "mumhash";
11
12 # Enable HTML fuzzy hashing
13 html_shingles = true;
14 min_html_tags = 5; # Low threshold for testing
15 html_weight = 1.0;
16
17 symbol = "FUZZY_HTML_TEST";
18 max_score = 10.0;
19
20 # Skip encryption for testing
21 # encryption_key = "";
22
23 fuzzy_map = {
24 "FUZZY_HTML_WHITELIST" {
25 flag = 1;
26 max_score = 10.0;
27 }
28 "FUZZY_HTML_SPAM" {
29 flag = 2;
30 max_score = 10.0;
31 }
32 }
33 }
34
35 # Rule with both text and HTML enabled
36 rule "TEST_COMBINED" {
37 servers = "localhost:11335";
38 algorithm = "mumhash";
39
40 html_shingles = true;
41 min_html_tags = 3;
42
43 symbol = "FUZZY_COMBINED_TEST";
44 max_score = 15.0;
45
46 fuzzy_map = {
47 "FUZZY_COMBINED_MATCH" {
48 flag = 10;
49 max_score = 15.0;
50 }
51 }
52 }
53 }