!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/pptp-server/   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:     save_options.cgi (2.56 KB)      -rwxr-xr-x
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
#!/usr/bin/perl
# save_options.cgi
# Save PPP server options

require './pptp-server-lib.pl';
$access{'options'} || &error($text{'options_ecannot'});
&error_setup($text{'options_err'});
&ReadParse();

$conf = &get_config();
$option = &find_conf("option", $conf);
$option ||= $config{'ppp_options'};
&lock_file($option);
@opts = &parse_ppp_options($option);

# Validate inputs
$in{'mtu_def'} || $in{'mtu'} =~ /^\d+$/ || &error($text{'options_emtu'});
$in{'mru_def'} || $in{'mru'} =~ /^\d+$/ || &error($text{'options_emru'});
$in{'name_def'} || $in{'name'} =~ /^[A-Za-z0-9\.\-]+$/ ||
    &error($text{'options_ename'});

# Save options
&save_ppp_option(\@opts, $option, "proxyarp",
         $in{'proxyarp'} ? { 'name' => 'proxyarp' } : undef);
&save_ppp_option(\@opts, $option, "lock",
         $in{'lock'} ? { 'name' => 'lock' } : undef);
&save_ppp_option(\@opts, $option, "mtu",
         $in{'mtu_def'} ? undef : { 'name' => 'mtu',
                        'value' => $in{'mtu'} });
&save_ppp_option(\@opts, $option, "mru",
         $in{'mru_def'} ? undef : { 'name' => 'mru',
                        'value' => $in{'mru'} });

if ($in{'auth'} == 0) {
    &save_ppp_option(\@opts, $option, "auth", undef);
    &save_ppp_option(\@opts, $option, "noauth", undef);
    }
elsif ($in{'auth'} == 1) {
    &save_ppp_option(\@opts, $option, "auth", undef);
    &save_ppp_option(\@opts, $option, "noauth", { 'name' => 'noauth' });
    }
else {
    &save_ppp_option(\@opts, $option, "noauth", undef);
    &save_ppp_option(\@opts, $option, "auth", { 'name' => 'auth' });
    }
&parse_auth("pap");
&parse_auth("chap");
&save_ppp_option(\@opts, $option, "login",
         $in{'login'} ? { 'name' => 'login' } : undef);
&save_ppp_option(\@opts, $option, "name",
        $in{'name_def'} ? undef : { 'name' => 'name',
                        'value' => $in{'name'} });

&foreign_require("pptp-client", "pptp-client-lib.pl");
&pptp_client::parse_mppe_options(\@opts, $option);

if (&pptp_client::mppe_support() == 1) {
    &parse_auth("mschap");
    &parse_auth("mschap-v2");
    }
else {
    &parse_auth("chapms");
    &parse_auth("chapms-v2");
    }

# All done
&flush_file_lines();
&unlock_file($option);
&webmin_log("options", undef, undef, \%in);
&redirect("");

# parse_auth(name)
sub parse_auth
{
local $a = $_[0];
if ($in{$a} == 2) {
    &save_ppp_option(\@opts, $option, "require-$a",
             { 'name' => "require-$a" });
    &save_ppp_option(\@opts, $option, "refuse-$a", undef);
    }
elsif ($in{$a} == 1) {
    &save_ppp_option(\@opts, $option, "require-$a", undef);
    &save_ppp_option(\@opts, $option, "refuse-$a", undef);
    }
else {
    &save_ppp_option(\@opts, $option, "require-$a", undef);
    &save_ppp_option(\@opts, $option, "refuse-$a",
             { 'name' => "refuse-$a" });
    }
}

:: 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.0187 ]--