← Prev in month
← Prev in thread
Need help forming html+xml message.
The gateway device response to the SSDP with LOCATION: http://192.168.2.1:80/x_internetgatewaydevice.xml Within that xml file there is refrence to x_wanipconnection.xml <SCPDURL>http://192.168.2.1:80/x_wanipconnection.xml</SCPDURL> and within that xml is the method I'm trying to invoke. The method is called GetExternalIPAddress. <action> <name>GetExternalIPAddress</name> <argumentList> <argument> <name>NewExternalIPAddress</name> <direction>out</direction> <relatedStateVariable>ExternalIPAddress</relatedStateVariable> </argument> </argumentList> </action> --------------- This is what I've formed but it doesn't work... Can you tell me what I've done wrong? POST /http://192.168.2.1:80/control?WANIPConnection HTTP/1.1 HOST: 192.168.2.1:80 SOAPACTION: "schemas-upnp-org:device:InternetGatewayDevice:1#GetExternalIPAddress" CONTENT-TYPE: text/xml ; charset="utf-8" Content-Length: 284 <?xml version="1.0"?> <soap:Envelope xmlns:soap="http://www.w3.org/2001/12/soap-envelope" soap:encodingStyle="http://www.w3.org/2001/12/soap-encoding"> <soap:Body> <m:GetExternalIPAddress xmlns:m=http://192.168.2.1:80/control?WANIPConnection"> </soap:Body> </soap:Envelope> ----------------------------------- This is what the server replies: ----------------------------------- HTTP/1.1 500 Internal Server Error Content-Type: text/xml; charset="utf-8" Content-Length: 400 Date: Wed, 22 Sep 2004 20:04:05 GMT Server: Custom/1.0 UPnP/1.0 Prod/Ver EXT: <s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/" s:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"> <s:Body> <s:Fault> <faultcode>s:Client</faultcode> <faultstring>UPnPError</faultstring> <detail> <UPnPError xmlns="urn:schemas-upnp-org:control-1-0"> <errorCode>401</errorCode> <errorDescription>Invalid Action</errorDescription> </UPnPError> </detail> </s:Fault> </s:Body> </s:Envelope> ______________________________________________________________________ Post your free ad now! http://personals.yahoo.ca
← Prev in month
← Prev in thread