{% extends "base.html" %} {% block title %}Scan History - Hermetic Suite{% endblock %} {% block content %}
{% if scans %} {% for scan in scans %} {% endfor %}
ID Date/Time Type Target Status Items Vulns Duration
#{{ scan.id }} {{ scan.created_at.strftime('%Y-%m-%d %H:%M:%S') if scan.created_at else '-' }} {% set type_labels = { 'server': 'Server', 'server_auth': 'Server (Auth)', 'domain': 'Domain', 'discovery': 'Discovery' } %} {{ type_labels.get(scan.scan_type.value, scan.scan_type.value) }} {% if scan.server %} {{ scan.server.ip_address }} {% elif scan.dns_record %} {{ scan.dns_record.hostname }} {% else %} Discovery {% endif %} {% set status_colors = { 'completed': 'success', 'running': 'warning', 'failed': 'danger', 'pending': 'secondary' } %} {{ scan.status.value|capitalize }} {# Items column: hosts_scanned for discovery, services_found for scans #} {% if scan.server or scan.dns_record %} {{ scan.services_found if scan.services_found is not none else '-' }} {% else %} {# Discovery scan - show hosts_scanned as items found #} {{ scan.hosts_scanned if scan.hosts_scanned else '-' }} {% endif %} {{ scan.vulnerabilities_found if scan.vulnerabilities_found is not none else '-' }} {% if scan.duration_seconds is not none and scan.duration_seconds >= 0 %} {{ scan.duration_seconds }}s {% elif scan.started_at and scan.completed_at %} {{ (scan.completed_at - scan.started_at).total_seconds()|int }}s {% elif scan.status.value == 'running' %} In progress... {% else %} - {% endif %}
{% else %}

No scan history yet. Run a discovery scan to get started.

{% endif %}
{% endblock %}