Skip to content

Commit

Permalink
sf: allow 60 seconds for post-scan correlations to complete (#1818)
Browse files Browse the repository at this point in the history
  • Loading branch information
bcoles authored Nov 5, 2023
1 parent e84db07 commit 1a9bcd7
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions sf.py
100755 → 100644
Original file line number Diff line number Diff line change
Expand Up @@ -442,6 +442,13 @@ def start_scan(sfConfig: dict, sfModules: dict, args, loggingQueue) -> None:
if not info:
continue
if info[5] in ["ERROR-FAILED", "ABORT-REQUESTED", "ABORTED", "FINISHED"]:
# allow 60 seconds for post-scan correlations to complete
timeout = 60
p.join(timeout=timeout)
if (p.is_alive()):
log.error(f"Timeout reached ({timeout}s) waiting for scan {scanId} post-processing to complete.")
sys.exit(-1)

if sfConfig['__logging']:
log.info(f"Scan completed with status {info[5]}")
if args.o == "json":
Expand Down

0 comments on commit 1a9bcd7

Please sign in to comment.