Debian Codegraph @

hub1/.tests/cve_2022_37042/scenario.assert

raw
1 len(results) == 2
2 "5.5.8.56" in results[0].Overflow.GetSources()
3 results[0].Overflow.Sources["5.5.8.56"].IP == "5.5.8.56"
4 results[0].Overflow.Sources["5.5.8.56"].Range == ""
5 results[0].Overflow.Sources["5.5.8.56"].GetScope() == "Ip"
6 results[0].Overflow.Sources["5.5.8.56"].GetValue() == "5.5.8.56"
7 results[0].Overflow.Alert.Events[0].GetMeta("datasource_path") == "cve_2022_37042.log"
8 results[0].Overflow.Alert.Events[0].GetMeta("datasource_type") == "file"
9 results[0].Overflow.Alert.Events[0].GetMeta("http_path") == "/service/extension/backup/mboximport?account-name=admin&account-status=1&ow=cmd"
10 results[0].Overflow.Alert.Events[0].GetMeta("http_status") == "401"
11 results[0].Overflow.Alert.Events[0].GetMeta("http_user_agent") == "Go-http-client/1.1"
12 results[0].Overflow.Alert.Events[0].GetMeta("http_verb") == "POST"
13 results[0].Overflow.Alert.Events[0].GetMeta("log_type") == "http_access-log"
14 results[0].Overflow.Alert.Events[0].GetMeta("service") == "http"
15 results[0].Overflow.Alert.Events[0].GetMeta("source_ip") == "5.5.8.56"
16 results[0].Overflow.Alert.Events[0].GetMeta("timestamp") == "2020-01-04T07:25:02Z"
17 results[0].Overflow.Alert.GetScenario() == "crowdsecurity/CVE-2022-37042"
18 results[0].Overflow.Alert.Remediation == true
19 results[0].Overflow.Alert.GetEventsCount() == 1
20 "5.5.8.5" in results[1].Overflow.GetSources()
21 results[1].Overflow.Sources["5.5.8.5"].IP == "5.5.8.5"
22 results[1].Overflow.Sources["5.5.8.5"].Range == ""
23 results[1].Overflow.Sources["5.5.8.5"].GetScope() == "Ip"
24 results[1].Overflow.Sources["5.5.8.5"].GetValue() == "5.5.8.5"
25 results[1].Overflow.Alert.Events[0].GetMeta("datasource_path") == "cve_2022_37042.log"
26 results[1].Overflow.Alert.Events[0].GetMeta("datasource_type") == "file"
27 results[1].Overflow.Alert.Events[0].GetMeta("http_path") == "/service/extension/backup/mboximport?account-name=admin&ow=2&no-switch=1&append=1"
28 results[1].Overflow.Alert.Events[0].GetMeta("http_status") == "404"
29 results[1].Overflow.Alert.Events[0].GetMeta("http_user_agent") == "Go-http-client/1.1"
30 results[1].Overflow.Alert.Events[0].GetMeta("http_verb") == "POST"
31 results[1].Overflow.Alert.Events[0].GetMeta("log_type") == "http_access-log"
32 results[1].Overflow.Alert.Events[0].GetMeta("service") == "http"
33 results[1].Overflow.Alert.Events[0].GetMeta("source_ip") == "5.5.8.5"
34 results[1].Overflow.Alert.Events[0].GetMeta("timestamp") == "2020-01-04T07:25:02Z"
35 results[1].Overflow.Alert.GetScenario() == "crowdsecurity/CVE-2022-37042"
36 results[1].Overflow.Alert.Remediation == true
37 results[1].Overflow.Alert.GetEventsCount() == 1