1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-06 04:31:29 +00:00
Commit Graph

14 Commits

Author SHA1 Message Date
dmiller
e4f65348cb Use lua_createtable to prealloc some tables, saving time & memory 2018-06-28 03:43:25 +00:00
david
bfd5d7c2ba Remove references to obsolete stdnse.c library. 2012-08-08 19:21:44 +00:00
batrick
000f6dc4d9 Lua 5.2 upgrade [1] for NSE.
[1] http://seclists.org/nmap-dev/2012/q2/34
2012-05-27 08:53:32 +00:00
djalal
6f57ba85ea Remove get_target() and get_port() function declaration from the nse_nmaplib.h since they are already declared in the nse_utility.h 2011-02-10 08:45:50 +00:00
batrick
ec79a3b59b Use defines for library names "nmap" and "stdnse.c" 2010-02-06 00:59:33 +00:00
david
7db7da0007 Merge again from /nmap-exp/david/nmap-mem; this fixes a couple of bugs. 2009-12-20 03:22:19 +00:00
david
1c6030709b Revert r16307:16309, the merge from nmap-mem. I just found a
segmentation fault which I am investigating.
2009-12-19 22:49:16 +00:00
david
b838242e01 Merge from /nmap-exp/david/nmap-mem. This brings in two memory-reducing
changes. The first is that Port objects don't allocate memory for
service and RPC results unless that information is set. This reduces the
size of a bare Port from 92 to 40 bytes on my machine. The second change
is that PortList now has the notion of a "default port state," which is
the state of any ports that didn't receive a response. These ports don't
need an allocated Port object, which saves a lot of memory in scans
where most ports didn't get a response.
2009-12-19 21:26:14 +00:00
batrick
37bbb40520 Merge of nse-lua (nse-lua-merge) minus most enchancements that were
not directly related to the change from C++ to Lua for the NSE main
procedures.

The changes are discussed in the nse-lua thread here:
http://seclists.org/nmap-dev/2009/q1/0047.html
2009-04-05 06:01:27 +00:00
batrick
07cfc5aee4 Corrected many #includes for header files (where they are included).
Moved the includes for Lua headers to the .cc files so they are
not needlessly, repeatedly included.

Similarly, moved some standard headers to the .cc files and reorganized
includes to be uniform for all nse_* source files.

Fixed whitespace (removed tabs).
2009-03-10 05:56:10 +00:00
david
a173fe6ce1 Add the stdnse.sleep function. 2009-02-23 23:57:39 +00:00
david
20cf487b33 Replace the mix of spaces and tabs in the main NSE files with uniform two-space
indents, which seems to be the dominant style.
2008-11-18 21:11:27 +00:00
batrick
d0bc640db8 Large recode of nse_init.cc
Now does most of it's work through Lua:

From Nmap-dev: "Many of the changes consist of changing how Nmap interfaces
with Lua that were sometimes awkward or inflexible. Most of the functions 
have been made to be callable directly by Lua which offers many technical
advantages: stack management is alleviated, errors are handled cleanly and
are more descriptive, and there is increased reusability."

Additionally:
   -- Moved all lua_State * symbols from "l" to "L". This is to maintain
      consistency with other Lua libraries (convention) and to make our macros portable.
   -- Moved file system manipulation over to nse_fs.cc (from nse_init.cc)
2008-05-31 02:39:27 +00:00
fyodor
b361685be8 NSE committed 2006-12-11 00:34:26 +00:00