forked from p15670423/monkey
Island: Use ip address in scan report
This commit is contained in:
parent
b7566a805b
commit
519f48b6d8
|
@ -120,7 +120,7 @@ class ReportService:
|
||||||
formatted_nodes.append(
|
formatted_nodes.append(
|
||||||
{
|
{
|
||||||
"hostname": machine.hostname,
|
"hostname": machine.hostname,
|
||||||
"ip_addresses": list(map(str, machine.network_interfaces)),
|
"ip_addresses": [str(iface.ip) for iface in machine.network_interfaces],
|
||||||
"accessible_from_nodes": list(
|
"accessible_from_nodes": list(
|
||||||
map(lambda m: m.dict(simplify=True), accessible_from)
|
map(lambda m: m.dict(simplify=True), accessible_from)
|
||||||
),
|
),
|
||||||
|
|
|
@ -48,14 +48,14 @@ MACHINES = [MACHINE_1, MACHINE_2, MACHINE_3, ISLAND_MACHINE]
|
||||||
EXPECTED_SCANNED_MACHINES = [
|
EXPECTED_SCANNED_MACHINES = [
|
||||||
{
|
{
|
||||||
"hostname": MACHINE_1.hostname,
|
"hostname": MACHINE_1.hostname,
|
||||||
"ip_addresses": list(map(str, MACHINE_1.network_interfaces)),
|
"ip_addresses": [str(iface.ip) for iface in MACHINE_1.network_interfaces],
|
||||||
"accessible_from_nodes": [ISLAND_MACHINE.dict(simplify=True)],
|
"accessible_from_nodes": [ISLAND_MACHINE.dict(simplify=True)],
|
||||||
"services": [],
|
"services": [],
|
||||||
"domain_name": "",
|
"domain_name": "",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"hostname": MACHINE_2.hostname,
|
"hostname": MACHINE_2.hostname,
|
||||||
"ip_addresses": list(map(str, MACHINE_2.network_interfaces)),
|
"ip_addresses": [str(iface.ip) for iface in MACHINE_2.network_interfaces],
|
||||||
"accessible_from_nodes": [MACHINE_1.dict(simplify=True)],
|
"accessible_from_nodes": [MACHINE_1.dict(simplify=True)],
|
||||||
"services": [],
|
"services": [],
|
||||||
"domain_name": "",
|
"domain_name": "",
|
||||||
|
|
Loading…
Reference in New Issue