Nmap Development mailing list archives

[nse] moving broadcast support to separate scripts


From: Patrik Karlsson <patrik () cqure net>
Date: Sat, 30 Oct 2010 16:37:15 +0200

Hi all,

I've started splitting the broadcast/multicast scripts in order to be able to run them separately.
So far, I've done the dns-service-discovery and I'm working on the upnp scripts right now.
I largely underestimated the job as I thought I would only copy the common code to a library and split the script logic.
I wasn't happy with the result as the library turned out ugly as hell, so I re-wrote some parts and structured it using 
the same convention I've used in the past.

I'm attaching the new library and the two scripts and would appreciate *a lot* if we could get them commited really 
soon so I can finally cross this of my list.
In order to test it you need a device responding to mDNS like a printer, Mac or any linux distribution running Avahi 
Daemon.
for multicast do:
sudo ./nmap -sU -p 5353 --script broadcast-dns-service-discovery

for unicast do:
sudo ./nmap -sU -p 5353 --script dns-service-discovery <ip>

If you get a response similar to what's in the script output section it works.
If you don't and your sure that the device *should* respond, run the script with -d3 or send me a packet capture of the 
response.

Thanks in advance,
Patrik

Attachment: mdns.lua
Description:

Attachment: broadcast-dns-service-discovery.nse
Description:

Attachment: dns-service-discovery.nse
Description:



--
Patrik Karlsson
http://www.cqure.net
http://www.twitter.com/nevdull77





_______________________________________________
Sent through the nmap-dev mailing list
http://cgi.insecure.org/mailman/listinfo/nmap-dev
Archived at http://seclists.org/nmap-dev/

Current thread: