Skip to content
Snippets Groups Projects
Commit e1f441b9 authored by Gioacchino Vino's avatar Gioacchino Vino
Browse files

Added logic accepted/know issues during oid validation

parent 55c585d2
No related branches found
No related tags found
1 merge request!144Debug paas ci
...@@ -464,9 +464,17 @@ class Task: ...@@ -464,9 +464,17 @@ class Task:
glob_threat = 'None' glob_threat = 'None'
for o, s, t, p in zip(o_ids, severities, treats, ports): for o, s, t, p in zip(o_ids, severities, treats, ports):
logging.debug(f"Detected oid: {o}, severity: {s}, threat: {t} and port: {p}") logging.debug(f"Detected oid: {o}, severity: {s}, threat: {t} and port: {p}")
if (o not in accepted_issues) and (o in known_issues):
logging.debug(f"Oid {o}, not accepted but known") if s >= 4:
continue if o in accepted_issues:
logging.debug(f"Oid {o} ACCEPTED")
else:
if o in known_issues:
logging.debug(f"Oid {o} DROPPED (not accepted but known)")
continue
else:
logging.debug(f"Oid {o} NEW (not accepted and not known)")
if p in report: if p in report:
if s > report[p]['severity']: if s > report[p]['severity']:
report[p] = {'severity': s, 'threat': t} report[p] = {'severity': s, 'threat': t}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment