!c99Shell v. 1.0 pre-release build #16!

Software: Apache/2.2.3 (CentOS). PHP/5.1.6 

uname -a: Linux mx-ll-110-164-51-230.static.3bb.co.th 2.6.18-194.el5PAE #1 SMP Fri Apr 2 15:37:44
EDT 2010 i686
 

uid=48(apache) gid=48(apache) groups=48(apache) 

Safe-mode: OFF (not secure)

/usr/libexec/webmin/lpadmin/   drwxr-xr-x
Free 53.79 GB of 127.8 GB (42.09%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     acl_security.pl (4.39 KB)      -rwxr-xr-x
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |

require 'lpadmin-lib.pl';

# acl_security_form(&options)
# Output HTML for editing security options for the lpadmin module
sub acl_security_form
{
print "<tr> <td valign=top><b>$text{'acl_printers'}</b></td>\n";
print "<td colspan=3>\n";
printf "<input name=printers_def type=radio value=1 %s> %s\n",
    $_[0]->{'printers'} eq '*' ? 'checked' : '', $text{'acl_pall'};
printf "<input name=printers_def type=radio value=0 %s> %s<br>\n",
    $_[0]->{'printers'} eq '*' ? '' : 'checked', $text{'acl_psel'};
print "<select name=printers multiple size=4 width=15>\n";
local @plist = &list_printers();
local ($p, %pcan);
map { $pcan{$_}++ } split(/\s+/, $_[0]->{'printers'});
foreach $p (@plist) {
    local $prn = &get_printer($p);
    printf "<option value=%s %s>%s (%s)\n",
        $p, $pcan{$p} ? 'selected' : '',
        $prn->{'desc'}, $p;
    }
print "</select></td> </tr>\n";

print "<tr> <td valign=top><b>$text{'acl_cancel'}</b></td> <td colspan=3>\n";
printf "<input type=radio name=cancel value=0 %s> $text{'no'}\n",
    $_[0]->{'cancel'} == 0 ? "checked" : "";
printf "<input type=radio name=cancel value=1 %s> $text{'yes'}\n",
    $_[0]->{'cancel'} == 1 ? "checked" : "";
printf "<input type=radio name=cancel value=2 %s> $text{'acl_listed'}<br>\n",
    $_[0]->{'cancel'} == 2 ? "checked" : "";
print "<select name=jobs multiple size=4 width=15>\n";
map { $jcan{$_}++ } split(/\s+/, $_[0]->{'jobs'});
foreach $p (@plist) {
    local $prn = &get_printer($p);
    printf "<option value=%s %s>%s (%s)\n",
        $p, $jcan{$p} ? 'selected' : '',
        $prn->{'desc'}, $p;
    }
print "</select></td> </tr>\n";

print "<tr> <td><b>$text{'acl_user'}</b></td> <td colspan=3>\n";
printf "<input type=radio name=user_def value=1 %s> %s\n",
    $_[0]->{'user'} eq '*' ? 'checked' : '', $text{'acl_user_all'};
printf "<input type=radio name=user_def value=2 %s> %s\n",
    $_[0]->{'user'} ? '' : 'checked', $text{'acl_user_this'};
printf "<input type=radio name=user_def value=0 %s>\n",
    $_[0]->{'user'} eq '*' || !$_[0]->{'user'} ? '' : 'checked';
printf "<input name=user size=13 value='%s'></td> </tr>\n",
    $_[0]->{'user'} eq '*' || !$_[0]->{'user'} ? '' : $_[0]->{'user'};

print "<tr> <td><b>$text{'acl_add'}</b></td>\n";
printf "<td><input type=radio name=add value=1 %s> $text{'yes'}\n",
    $_[0]->{'add'} ? "checked" : "";
printf "<input type=radio name=add value=0 %s> $text{'no'}</td>\n",
    $_[0]->{'add'} ? "" : "checked";

print "<td><b>$text{'acl_stop'}</b></td>\n";
printf "<td><input type=radio name=stop value=1 %s> $text{'yes'}\n",
    $_[0]->{'stop'} == 1 ? "checked" : "";
printf "<input type=radio name=stop value=2 %s> $text{'acl_restart'}\n",
    $_[0]->{'stop'} == 2 ? "checked" : "";
printf "<input type=radio name=stop value=0 %s> $text{'no'}</td> </tr>\n",
    $_[0]->{'stop'} == 0 ? "checked" : "";

print "<tr> <td><b>$text{'acl_view'}</b></td>\n";
printf "<td><input type=radio name=view value=1 %s> $text{'yes'}\n",
    $_[0]->{'view'} ? "checked" : "";
printf "<input type=radio name=view value=0 %s> $text{'no'}</td>\n",
    $_[0]->{'view'} ? "" : "checked";

print "<td><b>$text{'acl_test'}</b></td>\n";
printf "<td><input type=radio name=test value=1 %s> $text{'yes'}\n",
    $_[0]->{'test'} ? "checked" : "";
printf "<input type=radio name=test value=0 %s> $text{'no'}</td> </tr>\n",
    $_[0]->{'test'} ? "" : "checked";

print "<tr> <td><b>$text{'acl_delete'}</b></td>\n";
printf "<td><input type=radio name=delete value=1 %s> $text{'yes'}\n",
    $_[0]->{'delete'} ? "checked" : "";
printf "<input type=radio name=delete value=0 %s> $text{'no'}</td>\n",
    $_[0]->{'delete'} ? "" : "checked";

print "<td><b>$text{'acl_cluster'}</b></td>\n";
printf "<td><input type=radio name=cluster value=1 %s> $text{'yes'}\n",
    $_[0]->{'cluster'} ? "checked" : "";
printf "<input type=radio name=cluster value=0 %s> $text{'no'}</td> </tr>\n",
    $_[0]->{'cluster'} ? "" : "checked";

print "</tr>\n";
}

# acl_security_save(&options)
# Parse the form for security options for the lpadmin module
sub acl_security_save
{
if ($in{'printers_def'}) {
    $_[0]->{'printers'} = '*';
    }
else {
    $_[0]->{'printers'} = join(" ", split(/\0/, $in{'printers'}));
    }
$_[0]->{'cancel'} = $in{'cancel'};
$_[0]->{'jobs'} = $in{'cancel'} == 2 ? join(" ", split(/\0/, $in{'jobs'})) : "";
$_[0]->{'add'} = $in{'add'};
$_[0]->{'stop'} = $in{'stop'};
$_[0]->{'view'} = $in{'view'};
$_[0]->{'user'} = $in{'user_def'} == 1 ? '*' :
          $in{'user_def'} == 2 ? undef : $in{'user'};
$_[0]->{'delete'} = $in{'delete'};
$_[0]->{'test'} = $in{'test'};
$_[0]->{'cluster'} = $in{'cluster'};
}


:: Command execute ::

Enter:
 
Select:
 

:: Shadow's tricks :D ::

Useful Commands
 
Warning. Kernel may be alerted using higher levels
Kernel Info:

:: Preddy's tricks :D ::

Php Safe-Mode Bypass (Read Files)

File:

eg: /etc/passwd

Php Safe-Mode Bypass (List Directories):

Dir:

eg: /etc/

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

:: Go Dir ::
 
:: Go File ::
 

--[ c999shell v. 1.0 pre-release build #16 Modded by Shadow & Preddy | RootShell Security Group | r57 c99 shell | Generation time: 0.0116 ]--