e4380a1cf2 | ||
---|---|---|
README.md |
README.md
mdig
multicast dig
Create and capture mDNS query and response packets to disk as binary and/or JSON.
Options are similar to the Unix dig
command, but for mDNS.
See also dig.js
Install with git
# Install the latest of v1.x
npm install -g 'git+https://git@git.daplie.com/Daplie/mdig.git#v1'
# Install exactly v1.0.0
npm install -g 'git+https://git@git.daplie.com/Daplie/mdig.git#v1.0.0'
Install without git
Don't have git? Well, you can also bow down to the gods of the centralized, monopolized, concentrated, dictator-net (as we like to call it here at Daplie Labs), if that's how you roll:
npm install -g mdig
Usage
Format
mdig [TYPE] <query>
Example
mdig PTR _services._dns-sd._udp.local
defaults
When run with no options mdig
will run with these as the default:
mdig -p 5353 @224.0.0.251 PTR _services._dns-sd._udp.local +time=3
Non-standard mDNS
For debugging you may use a non-standard port and address
# non-standard port
mdig -p 1900
# non-standard broadcast address
mdig @239.255.255.250
Common Service Types
_ssh._tcp.local
_sftp-ssh._tcp.local"
_nfs._tcp.local
_pdl-datastream._tcp.local
_printer._tcp.local
_ipp._tcp.local
_http._tcp.local
_apple-mobdev2._tcp.local
_workstation._tcp.local
_udisks-ssh._tcp.local
Options
--debug
--output <path/to/file> write query and response(s) to disk with this path prefix (ex: ./samples/dns)
-t <type> (superfluous) default ANY (mdns default: PTR)
-c <class> default IN
-p <port> default 53 (mdns default: 5353) (listener is random for DNS and 5353 for mDNS)
-q <query> (superfluous) required (ex: daplie.com)
+time=<seconds> Sets the timeout for a query in seconds.