Skip to content

Commit

Permalink
Merge pull request #913 from OWASP/scan_id
Browse files Browse the repository at this point in the history
ScanID added to CLI and HTML report for easy identification of results
  • Loading branch information
securestep9 authored Sep 25, 2024
2 parents 1eb2d5e + 9b89749 commit 04549d9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
5 changes: 2 additions & 3 deletions nettacker/core/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -193,20 +193,19 @@ def run(self):
True when it ends
"""
scan_id = utils.generate_random_token(32)

log.info("ScanID: {0}".format(scan_id))
log.info(_("regrouping_targets"))
# find total number of targets + types + expand (subdomain, IPRanges, etc)
# optimize CPU usage
self.arguments.targets = self.expand_targets(scan_id)
if not self.arguments.targets:
log.info(_("no_live_service_found"))
return True

exit_code = self.start_scan(scan_id)
create_report(self.arguments, scan_id)
if self.arguments.scan_compare_id is not None:
create_compare_report(self.arguments, scan_id)
log.info(_("done"))
log.info("ScanID: {0} ".format(scan_id) + _("done"))

return exit_code

Expand Down
1 change: 1 addition & 0 deletions nettacker/core/graph.py
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,7 @@ def create_report(options, scan_id):
+ "</div>"
+ '<p class="footer">'
+ _("nettacker_version_details").format(version_info()[0], version_info()[1], now())
+ " ScanID: {0}".format(scan_id)
+ "</p>"
+ log_data.json_parse_js
)
Expand Down

0 comments on commit 04549d9

Please sign in to comment.