From 181a3bdc44a03e8ec50b76fafc4bd58c582a6a16 Mon Sep 17 00:00:00 2001 From: Jon Date: Sat, 24 Feb 2024 21:26:01 +0930 Subject: [PATCH] feat(scanner): Add scanner timezone to scan report !11 #13 --- playbooks/tasks/scan_subnet.yaml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/playbooks/tasks/scan_subnet.yaml b/playbooks/tasks/scan_subnet.yaml index 8c0f78c..b63fefb 100644 --- a/playbooks/tasks/scan_subnet.yaml +++ b/playbooks/tasks/scan_subnet.yaml @@ -44,7 +44,7 @@ {%- endfor %} "subnetId": "{{ subnet.id }}", "ip": "{{ scanned_host.address['@addr'] | default(scanned_host.address[0]['@addr']) }}", - "lastSeen": "{{ nmap_scan.start }}", + "lastSeen": "{{ (nmap_scan.start | split('.'))[0] }}", {% if scanned_host.hostnames.hostname is defined %} @@ -124,7 +124,8 @@ "code": "{{ nofusscomputing_phpipam_scan_agent.scanagent_code }}", "scan": { "subnet": "{{ subnet.address }}", - "results": "{{ subnet_scan_results }}" + "results": "{{ subnet_scan_results }}", + "tz": "{{ '%z' | strftime }}" } } validate_certs: true # Ensure always true