Skip to content
/ lsupnp Public

Command-line C program that discovers UPnP devices on a network.

License

Notifications You must be signed in to change notification settings

ccoff/lsupnp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

lsupnp

This is a command-line program that discovers all Universal Plug and Play (UPnP) devices on a network and lists them (lsupnp = list upnp). It does this by sending out an HTTP device discovery request to the SSDP multicast address and then listening for responses from UPnP devices.

For example, running this program on my home network reveals three UPnP devices: a NAS server, a Roku streaming player, and the router.

How to build

Assuming gcc and make are installed, building the program is as easy as running make from the source directory.

Usage

Type ./lsupnp at the command line. The following command-line options are available:

-p [port]: Bind the source UDP port to the specified port number. This option is useful if you are running a firewall, because devices send their responses to the same UDP port that sent the discovery request. Therefore you can add a firewall rule to allow device responses through on the specified port.

-r: Do a reverse DNS lookup on the IP address of any responding device.

-t [interval]: Specify the timeout interval in seconds. This controls how long to wait for SSDP responses.

-v: Display verbose information, such as raw HTTP headers and responses.

About

Command-line C program that discovers UPnP devices on a network.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published