mirror of
https://github.com/nmap/nmap.git
synced 2025-12-28 02:19:04 +00:00
[NSE] Added Boolean Operators for --script. You may now use a boolean operator
("and", "or", or "not") combined with categories, filenames, and filenames with
a '*', wildcard, to match many files. This change requires the script database
to be recompiled. Please see the thread at
http://seclists.org/nmap-dev/2009/q2/0100.html for more information.
This commit is contained in:
@@ -335,10 +335,11 @@ int script_updatedb (void)
|
||||
" ' categories field is not a table')\n"
|
||||
" local basename = assert(match(script, '[/\\\\]?([^/\\\\]-%.nse)$'))\n"
|
||||
" table.sort(categories)\n"
|
||||
" db:write('Entry { filename = \"', basename, '\", categories = {')\n"
|
||||
" for j, category in ipairs(categories) do\n"
|
||||
" db:write('Entry { category = \"', lower(category),"
|
||||
" '\", filename = \"', basename, '\" }\\n')\n"
|
||||
" db:write(' \"', lower(category), '\",')\n"
|
||||
" end\n"
|
||||
" db:write(' } }\\n')\n"
|
||||
"end\n"
|
||||
"db:close()\n";
|
||||
int status = SCRIPT_ENGINE_SUCCESS;
|
||||
|
||||
Reference in New Issue
Block a user