Skip to content

Instantly share code, notes, and snippets.

@denwilliams
Created March 22, 2014 06:00
Show Gist options
  • Star 3 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save denwilliams/9701993 to your computer and use it in GitHub Desktop.
Save denwilliams/9701993 to your computer and use it in GitHub Desktop.
curl -u admin -k -d command=poweroff -d shutdown_option=1 -d OPERATION=set -d PAGE=System -d OUTER_TAB=tab_shutdown -d INNER_TAB=none https://{$1}/get_handler|awk -F"message>" '{print $2}'|awk -F"</" '{print $1}'
or
curl -u admin:netgear1 -k -d command=poweroff -d shutdown_option=1 -d OPERATION=set -d PAGE=System -d OUTER_TAB=tab_shutdown -d INNER_TAB=none https://10.20.0.102/get_handler
or
curl -u $user:$pass -k "https://$host/admin/index.cgi?CURRENTTAB=Shutdown&CURRENTPAGE=System&MODE=Advanced&button=Current&command=poweroff&MODIFIED=1" >/dev/null 2>/dev/null
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment