Log summary of vulnerability scans - all data is in SQLite database.
(self)
| 751 | |
| 752 | |
| 753 | def save_summary(self): |
| 754 | """ |
| 755 | Log summary of vulnerability scans - all data is in SQLite database. |
| 756 | """ |
| 757 | try: |
| 758 | # Get statistics from database |
| 759 | all_hosts = self.db.get_all_hosts() |
| 760 | hosts_with_vulns = [h for h in all_hosts if h.get('vulnerabilities')] |
| 761 | |
| 762 | logger.info(f"="*60) |
| 763 | logger.info(f"VULNERABILITY SCAN SUMMARY") |
| 764 | logger.info(f"="*60) |
| 765 | logger.info(f"Total hosts scanned: {len(self.scan_results)}") |
| 766 | logger.info(f"Hosts with vulnerabilities: {len(hosts_with_vulns)}") |
| 767 | logger.info(f"All data stored in SQLite database: {self.db.db_path}") |
| 768 | logger.info(f"="*60) |
| 769 | except Exception as e: |
| 770 | logger.error(f"Error generating summary: {e}") |
| 771 | |
| 772 | def force_scan_all_hosts(self, real_time_callback=None): |
| 773 | """ |
no test coverage detected