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

30 Commits

Author SHA1 Message Date
dmiller
f8d4531b1f Make some broadcast scripts 'safe' category 2024-10-08 21:14:40 +00:00
dmiller
453f9a7e25 Use stdnse.get_script_interfaces() for all relevant scripts 2024-05-24 19:01:16 +00:00
dmiller
881d741dab Remove NSEdoc for newtargets arg, provided by targets.lua instead 2024-05-21 18:49:38 +00:00
dmiller
cb4b46bd53 Canonicalize authors as tables instead of comma-separated strings 2016-06-09 22:46:42 +00:00
dmiller
f4619edece Update http urls for nmap.org to https 2015-11-05 20:41:05 +00:00
dmiller
204d37e4d7 Replace packet.toip* and ip*tobin with ipOps.ip_to_str and str_to_ip 2015-02-27 19:42:46 +00:00
batrick
810f7d4803 more stdnse.print_debug -> stdnse.debug
This is a catchall pattern with a few exclusions.

$ sed -i 's/stdnse.print_debug( *\([0-9]*\) *, *\(.*\))/stdnse.debug\1(\2)/' *.nse
$ sed -i 's/stdnse.print_debug(\(.*\))/stdnse.debug1(\1)/' *.nse

Excluded:
$ svn revert db2-das-info.nse
$ svn revert flume-master-info.nse
$ svn revert http-headers.nse
$ svn revert http-methods.nse
$ svn revert http-unsafe-output-escaping.nse
$ svn revert http-userdir-enum.nse
$ svn revert http-vuln-cve2011-3192.nse
$ svn revert http-vuln-wnr1000-creds.nse
$ svn revert http-wordpress-plugins.nse
$ svn revert telnet-brute.nse
2014-08-02 02:46:16 +00:00
dmiller
ac5a89a8e1 Remove unused NSE library requires
for lib in nselib/*.lua*; do l=${lib#*/}; l=${l%.lua*}; find . -name \
  \*.lua -o -name \*.nse | xargs grep -l "require .$l\>" | xargs grep \
  -c "\<$l\." | grep ':0$' | awk -F: '{print "'$l'", $1}'; done

Did not remove calls to stdnse.silent_require since these can be used to
abort script execution if OpenSSL is not included, even if the script
does not directly call openssl.* (perhaps it uses comm.tryssl instead,
for instance).

Also did not remove require "strict", since that library is special and
modifies the environment.
2014-02-13 16:39:17 +00:00
dmiller
c7d4f2ec96 Re-indent some scripts. Whitespace-only commit
https://secwiki.org/w/Nmap/Code_Standards
2014-01-31 21:01:26 +00:00
dmiller
197f28265f New function stdnse.format_mac
This function will format a MAC address as colon-separated hex bytes.
It's really very simple: stdnse.tohex(mac, {separator=":"})

This commit updates all the instances I could find of the varying
convoluted attempts at performing this conversion.
2014-01-16 21:50:30 +00:00
patrik
448bb5a71b fixed a bug in a loop where the script would wait for a condition that was
supposed to be signalled by other threads which were no longer running.
2012-08-29 05:37:56 +00:00
batrick
2dcb08a590 Fix location of try/catch. The pcap/dnet variables were not in scope. 2012-06-06 21:36:02 +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
henri
1f431b953f Consistent naming of the address fields between IPv4 and IPv6.
All IP packet objects now have the following attributes:

  - ip_bin_src (binary src address)
  - ip_bin_dst (binary dst address)
  - ip_src (decimal-dotted string src address)
  - ip_dst (decimal-dotted string dst address)

The ip6_src and ip6_dst attributes have therefore been renamed (ip_bin_src and
ip_bin_dst).

This patch also updates the scripts accordingly.
2012-01-21 14:46:00 +00:00
david
1c297f9138 Check target.ALLOW_NEW_TARGETS. 2011-10-07 09:51:10 +00:00
david
2a696bc6ef Add @output to targets-ipv6-multicast-*. 2011-10-07 09:51:09 +00:00
david
705590ef47 Include MAC and interface name in targets-ipv6-multicast-* output. 2011-10-07 09:51:08 +00:00
david
0d6da1b8d3 Use all interfaces by default in targets-ipv6-multicast-*. 2011-10-07 09:51:07 +00:00
david
9e7db09d40 Show found addresses in targets-ipv6-multicast-*.
This is similar to a patch submitted by Daniel Miller.
2011-10-07 09:51:05 +00:00
fyodor
131dccc5d2 Some (mostly minor rewording) NSEDoc updates 2011-09-29 22:06:23 +00:00
tomsellers
1c92c03401 Add a few scripts to the "broadcast" script category based on traffic behavior. 2011-09-11 11:58:18 +00:00
david
4d0a8a27b1 Show a visible error when targets-ipv6-* are run without an interface. 2011-09-08 16:11:21 +00:00
weilin
f1ef57e961 o [NSE] Check the link type of the interface before sending the multicast host discovery probe. 2011-09-03 12:57:37 +00:00
djalal
fbd74b9d46 o [NSE] Use nmap.get_interface_info() to retrieve the interface information. 2011-09-03 10:38:38 +00:00
david
64722d1b7b Better docs for targets-ipv6-* scripts. 2011-09-02 04:11:06 +00:00
david
c497fb37a7 Remove unconditional debugging output from targets-ipv6-* scripts. 2011-09-02 04:11:05 +00:00
david
8d715c7a48 Remove the ipv6.src script argument. 2011-09-02 04:11:03 +00:00
david
5f217dee0a Use the SCRIPT_NAME prefix on the "interface" arg. 2011-09-02 04:11:02 +00:00
david
a0e4664f21 Whitespace. 2011-09-02 04:11:01 +00:00
david
113ef12106 Add IPv6 multicast host discovery scripts from Weilin. 2011-09-02 04:11:00 +00:00