Analyzer works. now need to add setup to Terraform and add new config

This commit is contained in:
Shay Nehmad 2020-02-23 17:26:29 +02:00
parent 20be94d606
commit 9965947d3f
3 changed files with 11 additions and 20 deletions

View File

@ -23,7 +23,7 @@ class PerformanceAnalyzer(Analyzer):
single_page_time_less_then_max = True single_page_time_less_then_max = True
for page, elapsed in timings: for page, elapsed in timings.items():
self.log.add_entry(f"page {page} took {str(elapsed)}") self.log.add_entry(f"page {page} took {str(elapsed)}")
total_time += elapsed total_time += elapsed
if elapsed > MAX_ALLOWED_SINGLE_PAGE_TIME: if elapsed > MAX_ALLOWED_SINGLE_PAGE_TIME:

View File

@ -1,17 +1,8 @@
{ {
"basic": { "basic": {
"credentials": { "credentials": {
"exploit_password_list": [ "exploit_password_list": [],
"Password1!", "exploit_user_list": []
"1234",
"password",
"12345678"
],
"exploit_user_list": [
"Administrator",
"root",
"user"
]
}, },
"general": { "general": {
"should_exploit": true "should_exploit": true
@ -48,7 +39,7 @@
"exploiter_classes": [ "exploiter_classes": [
"Struts2Exploiter" "Struts2Exploiter"
], ],
"skip_exploit_if_file_exist": false "skip_exploit_if_file_exist": true
}, },
"ms08_067": { "ms08_067": {
"ms08_067_exploit_attempts": 5, "ms08_067_exploit_attempts": 5,
@ -140,19 +131,19 @@
"life_cycle": { "life_cycle": {
"max_iterations": 1, "max_iterations": 1,
"retry_failed_explotation": true, "retry_failed_explotation": true,
"timeout_between_iterations": 100, "timeout_between_iterations": 30,
"victims_max_exploit": 7, "victims_max_exploit": 7,
"victims_max_find": 30 "victims_max_find": 30
}, },
"system_info": { "system_info": {
"collect_system_info": true, "collect_system_info": false,
"extract_azure_creds": true, "extract_azure_creds": false,
"should_use_mimikatz": true "should_use_mimikatz": false
} }
}, },
"network": { "network": {
"ping_scanner": { "ping_scanner": {
"ping_scan_timeout": 1000 "ping_scan_timeout": 100
}, },
"tcp_scanner": { "tcp_scanner": {
"HTTP_PORTS": [ "HTTP_PORTS": [
@ -164,7 +155,7 @@
], ],
"tcp_scan_get_banner": true, "tcp_scan_get_banner": true,
"tcp_scan_interval": 0, "tcp_scan_interval": 0,
"tcp_scan_timeout": 3000, "tcp_scan_timeout": 300,
"tcp_target_ports": [ "tcp_target_ports": [
22, 22,
2222, 2222,

View File

@ -70,7 +70,7 @@ class TestMonkeyBlackbox(object):
def run_performance_test(island_client, conf_filename, test_name, timeout_in_seconds=DEFAULT_TIMEOUT_SECONDS): def run_performance_test(island_client, conf_filename, test_name, timeout_in_seconds=DEFAULT_TIMEOUT_SECONDS):
config_parser = IslandConfigParser(conf_filename) config_parser = IslandConfigParser(conf_filename)
analyzers = [ analyzers = [
CommunicationAnalyzer(island_client, config_parser.get_ips_of_targets()), # TODO CommunicationAnalyzer(island_client, config_parser.get_ips_of_targets()),
PerformanceAnalyzer(island_client), PerformanceAnalyzer(island_client),
] ]
log_handler = TestLogsHandler(test_name, island_client, TestMonkeyBlackbox.get_log_dir_path()) log_handler = TestLogsHandler(test_name, island_client, TestMonkeyBlackbox.get_log_dir_path())