1
0
mirror of https://github.com/nmap/nmap.git synced 2026-01-02 04:49:02 +00:00

Every ipOps function validates IP addresses, so no need to do it explicitly

This commit is contained in:
dmiller
2015-12-19 15:25:43 +00:00
parent 566120ca58
commit a11db08325
2 changed files with 1 additions and 3 deletions

View File

@@ -71,7 +71,6 @@ local function get_interfaces()
local interfaces = {}
for _, if_table in pairs(nmap.list_interfaces()) do
if (interface_name == nil or if_table.device == interface_name) -- check for correct interface
and ipOps.ip_to_str(if_table.address) -- validate IP address
and ipOps.ip_in_range(if_table.address, "fe80::/10") -- link local address
and if_table.link == "ethernet" then -- not the loopback interface
table.insert(interfaces, if_table)