Getting the DSL linespeed from the Fritz!Box 7360 / 2014-11-26

2014-11-26 Getting the DSL linespeed from the Fritz!Box 7360 4 years ago
The fact I couldn't get the DSL linespeed from the Fritz!Box 7360 annoyed me a lot, especially since there is a new telephone wiring cabinet which should raise VDSL2 speeds. I went through a number of websites about getting data out of the Fritz!Box with upnp, and finally I made it work and I get the results I want:
The hint that worked for me was at MRTG en Fritz!Box 7360 (firmware 124.06.05) - tweakers (in Dutch) where it mentiones the changeover to TR-064 protocol which should be reachable over the url which will ask for authentication with the root username and the Fritz!Box password. More about the Fritz!Box TR-064 implementation at Schnittstellen für Entwickler | AVM Deutschland (in German) which has more documentation at AVM TR-064 – First Steps (pdf, English). This made me end up at doing a SOAP request (post) to which failed. All SOAP requests fail with an HTTP error code 500, but there is a separate SOAP error set in the HTTP status 500 body. I used tcpdump to look at the SOAP error body and found:
<errorCode>504</errorCode> <errorDescription>SSL needed</errorDescription></UPnPError>
The SSL port is (according to the TR-064 first steps document above) 49443 and the URL is over SSL: and this works, giving the answers I want.

The full script that fetches data:


wget --user=$FRITZUSER --password=$FRITZPASS --post-file=linkstatusrequest.xml \
--header="Content-Type: text/xml" \
--header="SOAPAction: \"urn:dslforum-org:service:WANCommonInterfaceConfig:1#GetCommonLinkProperties\"" --no-check-certificate \ -O linkstatusanswer.xml
This does need the linkstatusrequest.xml file:
<?xml version="1.0" encoding="utf-8"?>
      <u:GetCommonLinkProperties xmlns:u="urn:dslforum-org:service:WANCommonInterfaceConfig:1">
And gives me the right answer:
<?xml version="1.0"?>
<s:Envelope xmlns:s="" s:encodingStyle="">
<u:GetCommonLinkPropertiesResponse xmlns:u="urn:dslforum-org:service:WANCommonInterfaceConfig:1">
Which I can import into my rrdtool scripts and make into pretty graphs. VDSL downstream graph

Which directly shows me something interesting: the DSL linespeed is varying constantly.

Tags: , ,

, reachable as PGP encrypted e-mail preferred.

PGP key 5BA9 368B E6F3 34E4 local copy PGP key 5BA9 368B E6F3 34E4 via keyservers pgp key statistics for 0x5BA9368BE6F334E4 Koos van den Hout
Other webprojects: Camp Wireless, wireless Internet access at campsites, The Virtual Bookcase, book reviews
This page generated in 0.004491 seconds.