mirror of
https://github.com/nmap/nmap.git
synced 2025-12-09 06:01:28 +00:00
Remove unneeded requires
This commit is contained in:
@@ -3,7 +3,6 @@ local bit = require "bit"
|
|||||||
local comm = require "comm"
|
local comm = require "comm"
|
||||||
local json = require "json"
|
local json = require "json"
|
||||||
local lpeg = require "lpeg"
|
local lpeg = require "lpeg"
|
||||||
local match = require "match"
|
|
||||||
local math = require "math"
|
local math = require "math"
|
||||||
local nmap = require "nmap"
|
local nmap = require "nmap"
|
||||||
local stdnse = require "stdnse"
|
local stdnse = require "stdnse"
|
||||||
|
|||||||
@@ -519,8 +519,8 @@ udp = {
|
|||||||
local p = packet.Packet:new( layer3, #layer3 )
|
local p = packet.Packet:new( layer3, #layer3 )
|
||||||
local data = layer3:sub(p.udp_offset + 9)
|
local data = layer3:sub(p.udp_offset + 9)
|
||||||
|
|
||||||
local dhcpv6 = require("dhcp6")
|
local dhcp6 = require("dhcp6")
|
||||||
local resp = dhcpv6.DHCP6.Response.parse(data)
|
local resp = dhcp6.DHCP6.Response.parse(data)
|
||||||
|
|
||||||
for _, v in ipairs(resp.opts or {}) do
|
for _, v in ipairs(resp.opts or {}) do
|
||||||
if v.resp and v.resp.fqdn then
|
if v.resp and v.resp.fqdn then
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
--
|
--
|
||||||
|
|
||||||
local bin = require('bin')
|
local bin = require('bin')
|
||||||
local ipops = require('ipOps')
|
local ipOps = require('ipOps')
|
||||||
local match = require('match')
|
local match = require('match')
|
||||||
local nmap = require('nmap')
|
local nmap = require('nmap')
|
||||||
local stdnse = require('stdnse')
|
local stdnse = require('stdnse')
|
||||||
@@ -481,10 +481,10 @@ Helper = {
|
|||||||
local pos, is_ipv4 = bin.unpack("A12", addr)
|
local pos, is_ipv4 = bin.unpack("A12", addr)
|
||||||
if ( is_ipv4 == "\0\0\0\0\0\0\0\0\0\0\xFF\xFF" ) then
|
if ( is_ipv4 == "\0\0\0\0\0\0\0\0\0\0\xFF\xFF" ) then
|
||||||
local pos, bin_ip = bin.unpack("B4", addr, 13)
|
local pos, bin_ip = bin.unpack("B4", addr, 13)
|
||||||
addr = ipops.bin_to_ip(bin_ip)
|
addr = ipOps.bin_to_ip(bin_ip)
|
||||||
else
|
else
|
||||||
local pos, bin_ip = bin.unpack("B16", addr)
|
local pos, bin_ip = bin.unpack("B16", addr)
|
||||||
addr = ipops.bin_to_ip(bin_ip)
|
addr = ipOps.bin_to_ip(bin_ip)
|
||||||
end
|
end
|
||||||
elseif ( attr.tag == Attribute.Tag.ISNS_TAG_PORTAL_TCP_UDP_PORT ) then
|
elseif ( attr.tag == Attribute.Tag.ISNS_TAG_PORTAL_TCP_UDP_PORT ) then
|
||||||
local pos, s1
|
local pos, s1
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
local nmap = require "nmap"
|
local nmap = require "nmap"
|
||||||
local packet = require "packet"
|
|
||||||
local stdnse = require "stdnse"
|
local stdnse = require "stdnse"
|
||||||
local string = require "string"
|
local string = require "string"
|
||||||
local target = require "target"
|
local target = require "target"
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
local nmap = require "nmap"
|
local nmap = require "nmap"
|
||||||
local packet = require "packet"
|
|
||||||
local stdnse = require "stdnse"
|
local stdnse = require "stdnse"
|
||||||
local string = require "string"
|
local string = require "string"
|
||||||
local os = require "os"
|
local os = require "os"
|
||||||
|
|||||||
@@ -44,14 +44,12 @@ license = "Same as Nmap--See https://nmap.org/book/man-legal.html"
|
|||||||
|
|
||||||
categories = {"external", "discovery"}
|
categories = {"external", "discovery"}
|
||||||
|
|
||||||
local ipOps = require "ipOps"
|
|
||||||
local io = require "io"
|
local io = require "io"
|
||||||
local http = require "http"
|
local http = require "http"
|
||||||
local stdnse = require "stdnse"
|
local stdnse = require "stdnse"
|
||||||
local string = require "string"
|
local string = require "string"
|
||||||
local target = require "target"
|
local target = require "target"
|
||||||
local table = require "table"
|
local table = require "table"
|
||||||
local shortport = require "shortport"
|
|
||||||
|
|
||||||
-- Different from stdnse.get_hostname
|
-- Different from stdnse.get_hostname
|
||||||
-- this function returns nil if the host is only known by IP address
|
-- this function returns nil if the host is only known by IP address
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
local comm = require "comm"
|
|
||||||
local coroutine = require "coroutine"
|
local coroutine = require "coroutine"
|
||||||
local math = require "math"
|
local math = require "math"
|
||||||
local nmap = require "nmap"
|
local nmap = require "nmap"
|
||||||
|
|||||||
Reference in New Issue
Block a user