查看Upnp的源代码
←
Upnp
跳转到:
导航
,
搜索
因为以下原因,你没有权限编辑本页:
您刚才请求的操作只有这个用户组中的用户才能使用:
用户
您可以查看并复制此页面的源代码:
== Hacking == <source lang=bash> $ cat request.txt M-SEARCH * HTTP/1.1 HOST: 239.255.255.250:1900 MAN: "ssdp:discover" MX: 3 ST: urn:schemas-upnp-org:device:InternetGatewayDevice:1 $ nc -uvv 239.255.255.250 1900 < request.txt Connection to 239.255.255.250 1900 port [udp/ssdp] succeeded! $ socat -T1 STDIO UDP4-DATAGRAM:239.255.255.250:1900 < request.txt $ sudo tcpdump -vv -A -s 0 -i wlan0 udp port 1900 and host 239.255.255.250 tcpdump: listening on wlan0, link-type EN10MB (Ethernet), capture size 262144 bytes 17:50:46.507671 IP (tos 0x0, ttl 1, id 18834, offset 0, flags [none], proto UDP (17), length 201) localhost.57277 > 239.255.255.250.1900: [udp sum ok] UDP, length 173 E...I..........;.......l..&1M-SEARCH * HTTP/1.1 HOST: 239.255.255.250:1900 MAN: "ssdp:discover" MX: 1 ST: urn:dial-multiscreen-org:service:dial:1 USER-AGENT: Google Chrome/56.0.2924.87 Windows 17:50:58.181673 IP (tos 0x0, ttl 1, id 22084, offset 0, flags [none], proto UDP (17), length 202) localhost.52827 > 239.255.255.250.1900: [udp sum ok] UDP, length 174 E...VD.........A.....[.l....M-SEARCH * HTTP/1.1 HOST: 239.255.255.250:1900 MAN: "ssdp:discover" MX: 1 ST: urn:dial-multiscreen-org:service:dial:1 USER-AGENT: Google Chrome/55.0.2883.95 Mac OS X 17:49:42.200862 IP (tos 0x0, ttl 4, id 64314, offset 0, flags [DF], proto UDP (17), length 150) localhost.50000 > 239.255.255.250.1900: [udp sum ok] UDP, length 122 E....:@....<...=.....P.l..b:M-SEARCH * HTTP/1.1 HOST: 239.255.255.250:1900 MAN: "ssdp:discover" MX: 15 ST: urn:schemas-upnp-org:device:basic:1 17:49:42.414950 IP (tos 0x0, ttl 4, id 64325, offset 0, flags [DF], proto UDP (17), length 135) localhost.50000 > 239.255.255.250.1900: [udp sum ok] UDP, length 107 E....E@....@...=.....P.l.s..M-SEARCH * HTTP/1.1 HOST: 239.255.255.250:1900 MAN: "ssdp:discover" MX: 15 ST: urn:Belkin:device:** NOTIFY * HTTP/1.1 Host: 239.255.255.250:1900 Cache-Control: max-age=60 Location: http://192.168.1.1:1780/InternetGatewayDevice.xml NTS: ssdp:alive Server: POSIX, UPnP/1.0 linux/5.100.104.2 NT: urn:schemas-upnp-org:device:InternetGatewayDevice:1 </source> <source lang=bash> POST /upnp/control?WANIPConnection HTTP/1.1 Host: 192.168.1.1 SOAPAction: "urn:schemas-upnp-org:service:WANIPConnection:1#GetExternalIPAddress" Accept-Language: de-de;q=1, de;q=0.5 Accept-Encoding: gzip Content-Type: text/xml; charset="utf-8" User-Agent: gupnp-universal-cp GUPnP/0.20.10 DLNADOC/1.50 Connection: Keep-Alive Content-Length: 281 <?xml version="1.0"?> <s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/" s:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"> <s:Body> <u:GetExternalIPAddress xmlns:u="urn:schemas-upnp-org:service:WANIPConnection:1"></u:GetExternalIPAddress> </s:Body> </s:Envelope> </source> <source lang=bash> HTTP/1.1 200 OK EXT: Content-Type: text/xml; charset="utf-8" Date: Tue, 04 Aug 2015 23:55:01 GMT Server: servername/2.0 UPnP/1.0 UPnP-Device-Host/1.0 Content-Length: 380 <?xml version="1.0"?> <s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/" s:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"> <s:Body> <u:GetExternalIPAddressResponse xmlns:u="urn:schemas-upnp-org:service:WANIPConnection:1"> <NewExternalIPAddress>123.123.123.123</NewExternalIPAddress> </u:GetExternalIPAddressResponse> </s:Body> </s:Envelope> </source> <br><br>
返回到
Upnp
。
个人工具
登录
名字空间
页面
讨论
变换
查看
阅读
查看源代码
查看历史
操作
搜索
导航
首页
社区专页
新闻动态
最近更改
随机页面
帮助
工具箱
链入页面
相关更改
特殊页面