[Add Scan]

This commit is contained in:
2025-11-11 21:43:24 +01:00
parent 45a8fa4398
commit e4fa6510e8

View File

@@ -116,6 +116,8 @@
single_branch: yes
force: true
delegate_to: localhost
become: false
- ansible.builtin.command:
cmd: "masscan {{ target_network }} -p{{ target_port }}"
@@ -135,6 +137,7 @@
port: "{{ item.split('/')[0].split(' ')[-1]|int }}"
asn1_base64: true
delegate_to: localhost
become: false
run_once: true
loop: "{{ scan_output.stdout_lines }}"
ignore_errors: true
@@ -179,6 +182,7 @@
# loop_control:
# index_var: my_idx
delegate_to: localhost
become: false
#run_once: true
when:
- item.invocation is defined
@@ -193,6 +197,7 @@
loop_control:
index_var: my_idx
delegate_to: localhost
become: false
when: item.invocation is defined
- ansible.builtin.shell: |
@@ -205,6 +210,8 @@
chdir: "{{ playbook_dir }}/scan/"
run_once: true
delegate_to: localhost
become: false
- community.docker.docker_container_exec:
container: scan
@@ -241,5 +248,6 @@
ta: "file_folder"
body: "{{ target_network }}"
status_code: 200
tags: test1
delegate_to: localhost
become: false