Why can't i find this upnp device (http://192.168.61.1:5000/rootDesc.xml)?
siredwin opened this issue · 5 comments
Is it a subnet issue?
I can find this device using a third party app.
Finally i can load it by url
<root xmlns="urn:schemas-upnp-org:device-1-0"> <specVersion> <major>1</major> <minor>0</minor> </specVersion> <device> <deviceType> urn:schemas-upnp-org:device:InternetGatewayDevice:1 </deviceType> <friendlyName>OpenWRT router</friendlyName> <manufacturer>OpenWRT</manufacturer> <manufacturerURL>http://www.openwrt.org/</manufacturerURL> <modelDescription>OpenWRT router</modelDescription> <modelName>OpenWRT router</modelName> <modelNumber>1</modelNumber> <modelURL>http://www.openwrt.org/</modelURL> <serialNumber>00000000</serialNumber> <UDN>uuid:8d483abf-ca0e-45cc-9b....</UDN> <serviceList> <service> <serviceType>urn:schemas-upnp-org:service:Layer3Forwarding:1</serviceType> <serviceId>urn:upnp-org:serviceId:Layer3Forwarding1</serviceId> <controlURL>/ctl/L3F</controlURL> <eventSubURL>/evt/L3F</eventSubURL> <SCPDURL>/L3F.xml</SCPDURL> </service> </serviceList> <deviceList> <device> <deviceType>urn:schemas-upnp-org:device:WANDevice:1</deviceType> <friendlyName>WANDevice</friendlyName> <manufacturer>MiniUPnP</manufacturer> <manufacturerURL>http://miniupnp.free.fr/</manufacturerURL> <modelDescription>WAN Device</modelDescription> <modelName>WAN Device</modelName> <modelNumber>20160127</modelNumber> <modelURL>http://miniupnp.free.fr/</modelURL> <serialNumber>00000000</serialNumber> <UDN>uuid:8d483abf-ca0e-4f</UDN> <UPC>000000000000</UPC> <serviceList> <service> <serviceType> urn:schemas-upnp-org:service:WANCommonInterfaceConfig:1 </serviceType> <serviceId>urn:upnp-org:serviceId:WANCommonIFC1</serviceId> <controlURL>/ctl/CmnIfCfg</controlURL> <eventSubURL>/evt/CmnIfCfg</eventSubURL> <SCPDURL>/WANCfg.xml</SCPDURL> </service> </serviceList> <deviceList> <device> <deviceType>urn:schemas-upnp-org:device:WANConnectionDevice:1</deviceType> <friendlyName>WANConnectionDevice</friendlyName> <manufacturer>MiniUPnP</manufacturer> <manufacturerURL>http://miniupnp.free.fr/</manufacturerURL> <modelDescription>MiniUPnP daemon</modelDescription> <modelName>MiniUPnPd</modelName> <modelNumber>20160127</modelNumber> <modelURL>http://miniupnp.free.fr/</modelURL> <serialNumber>00000000</serialNumber> <UDN>uuid:8d483abf-ca0e-45cc-9bf0</UDN> <UPC>000000000000</UPC> <serviceList> <service> <serviceType>urn:schemas-upnp-org:service:WANIPConnection:1</serviceType> <serviceId>urn:upnp-org:serviceId:WANIPConn1</serviceId> <controlURL>/ctl/IPConn</controlURL> <eventSubURL>/evt/IPConn</eventSubURL> <SCPDURL>/WANIPCn.xml</SCPDURL> </service> </serviceList> </device> </deviceList> </device> </deviceList> <presentationURL>http://192....1/</presentationURL> </device> </root>
It's not clear what's causing this not to be found. What would be most useful is a filtered packet dump of what UDP packets came from 192.168.61.1 (or whatever IP the device is on at the time) in the two situations:
- when asking goupnp to discover devices
- when the third party app is discovering
Filtered especially to avoid over-sharing what's happening on your home network.
Particularly of interest are UDP packets that contain something looking like an HTTP response.
The router is safe. It is for testing purposes only on the local network and nothing important connects to it.
What UDP packets are you implying? Unfortunately, the third party app(android - app) manages to find urls from both of my UPnP enabled routers in less than 5 seconds but none of the Go packages do.
From your description I'm assuming that you're using goupnp to discover the router on your network, and it's failing to do so. (sidenote: do you have the code snippet?)
UPnP uses a few protocols to work. The discovery portion of it sends UDP to the local network, and then it listens for replies from devices. I'm guessing that some portion of this discovery process is not working.
I am just running the examples for now.
// Use discovered WANIPConnection2 services to find external IP addresses.
func Example_WANIPConnection2_GetExternalIPAddress() {
clients, errors, err := internetgateway2.NewWANIPConnection1Clients()
extIPClients := make([]GetExternalIPAddresser, len(clients))
for i, client := range clients {
extIPClients[i] = client
}
DisplayExternalIPResults(extIPClients, errors, err)
// Output:
}
//Successfully discovered 0 services:
Fixed!
It was my local firewall.
Now I will try to figure out which ports I need to open locally.