#!/bin/sh #NAME: Web-Shell #DESCRIPTION: Execute a shell command via the web interface. HOME="../plugin.cgi" . /webs/cgi-bin/login.cgi if [ "$action" = "3" ]; then cmd=`echo $cmd|sed -e 's/+/ /g'|sed -e 's/%/\\\x/g'|sed -e 's/[\]x0[dD][\]x0[aA]//g'` cmd_html=`echo -e $cmd " "|sed -e 's/\"/\"/g'` fi cat << EOF_HTML Content-type: text/html Connection: close
' echo -e "Web-Shell> " $cmd eval `echo -e $cmd 2>&1` echo '' fi cat << EOF_HTML
Execute a shell command.
Command
Enter the command to execute.