Monitoring TP-Link Powerline speeds on a TL-WPA8630P

Submitted by Falken on

Edit This no longer works on the latest firmware because the calls are now encrypted. It's trivial to reverse with the AES key just being based on timestamp, but there is an easier way :
Monitoring Powerline speeds ( TP-Link TL-WPA8630P, TL-PA8033PKIT, AV1300)

Firstly, you'll need to use your web browser's network debug panel to intercept a login request to the access points web GUI.
You'll want to find the 'Basic admin' cookie.

That done, just replace both 'x.y.z.w' with your devices IP address, and put the key in 'PUT YOUR KEY HERE'.

The script requires the standard 'curl' command, and also the 'jq' command to understand the output. If you don't have them. they'll be in your standard repositories.

I've got two other powerline devices, but couldn't get a loop to work over them. You can copy the sections at the end for as many other devices as you have.


curl -s 'http://x.y.z.w/admin/powerline?form=plc_device' -H 'User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:71.0) Gecko/20100101 Firefox/71.0' -H 'Accept: application/json, text/javascript, */*; q=0.01' -H 'Accept-Language: en-GB,en;q=0.5' --compressed -H 'Content-Type: application/x-www-form-urlencoded; charset=UTF-8' -H 'X-Requested-With: XMLHttpRequest' -H 'Origin:' -H 'Connection: keep-alive' -H 'Referer: http://x.y.z.w/' -H 'Cookie: Authorization=Basic%20admin%3A3 PUT YOUR KEY HERE' -H 'Pragma: no-cache' -H 'Cache-Control: no-cache' --data 'operation=load' > /tmp/powerline.json

isOK=`cat /tmp/powerline.json|jq '.success'`
if [ "$isOK" != "true" ]
echo "error"
exit 1

cat /tmp/powerline.json | jq '.data[0] | to_entries | .[2],.[3]|.key,.value'|xargs > /tmp/powerline_0
cat /tmp/powerline.json | jq '.data[1] | to_entries | .[2],.[3]|.key,.value'|xargs > /tmp/powerline_1

a=`cat /tmp/powerline_0`
aa=( $a )

b=`cat /tmp/powerline_1`
bb=( $b )

echo rx_rate_0:${aa[1]} tx_rate_0:${aa[3]} rx_rate_1:${bb[1]} tx_rate_1:${bb[3]}