From 2626e57b67c76cf8bb0c0332e433baea0f356cf8 Mon Sep 17 00:00:00 2001
From: "gioacchino.vino" <gioacchino.vino@infn.it>
Date: Fri, 29 Sep 2023 13:09:18 +0200
Subject: [PATCH] Tuned threshold for report severity

---
 files/script.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/files/script.py b/files/script.py
index 09a1dba..04f426a 100644
--- a/files/script.py
+++ b/files/script.py
@@ -386,7 +386,7 @@ def process_global_reports_info(reports):
             glob_threat = reports[host]['global']['threat']
     reports['deployment'] = {'severity': glob_severity, 
                              'threat': glob_threat}
-    if reports['deployment']['severity'] < 2:
+    if reports['deployment']['severity'] < 4:
         reports['global'] = "OK"
     else:
         reports['global'] = "NOK"
@@ -507,4 +507,4 @@ for host,ports in endpoints.items():
 
 reports = process_global_reports_info(reports)
 with open(summary_filename, "w") as f:
-    f.write(json.dumps(reports))  
\ No newline at end of file
+    f.write(json.dumps(reports))  
-- 
GitLab