How to restart a router with curl or wget to pass URL as well as POST parameters?

1

I have an Edimax router and from wireshark I see that the router restarts with the POST http://192.168.2.1/goform/formReboot and the form elements reset_flag=0&submit-url=%2Fadmin_restart.asp

Using curl and wget I have tried different methods of POST, but I have been unsuccessful. If I go directly to formReboot I get a 404 error. If I use POST I get an empty reply from server and no restart...

Here is an example:

curl -u 'admin:pass' --form 'reset_flag=0&submit-url=%2Fadmin_restart.asp' 'http://192.168.2.1/goform/formReboot

jakethedog

Posted 2014-10-14T01:38:10.027

Reputation: 740

Answers

0

Just managed to reboot an Edimax/Medion MD86833 WLAN repeater using curl -u 'admin:pass' --form 'reset_flag=0&submit-url=%2Fcontool.asp' 'http://192.168.1.201/goform/formReboot'

martin

Posted 2014-10-14T01:38:10.027

Reputation: 1

0

The examples from the cURL command show that you separate the form entries using ; instead of &. You might want to try that.

Also, curl --verbose ... will give you more details that might help you find out what the problem is.

DavidG

Posted 2014-10-14T01:38:10.027

Reputation: 311