!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/change-user/   drwxr-xr-x
Free 50.93 GB of 127.8 GB (39.85%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     change.cgi (2.36 KB)      -rwxr-xr-x
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
#!/usr/bin/perl
# change.cgi
# Make all the changes, and re-direct to / in case the theme has changed

use strict;
use warnings;
require './change-user-lib.pl';
our (%text, %in, %gconfig, $base_remote_user, %access);
&ReadParse();

my @users = &acl::list_users();
my ($user) = grep { $_->{'name'} eq $base_remote_user } @users;
my $oldtheme = $user->{'theme'};
my $oldoverlay = $user->{'overlay'};
if (!defined($oldtheme)) {
    ($oldtheme, $oldoverlay) = split(/\s+/, $gconfig{'theme'});
    }

# Validate the password
if ($access{'pass'} && &can_change_pass($user) && !$in{'pass_def'}) {
    $in{'pass'} =~ /:/ && &error($text{'change_ecolon'});
    $in{'pass'} eq $in{'pass2'} ||
        &error($text{'change_epass2'});
    my $perr = &acl::check_password_restrictions(
        $user->{'name'}, $in{'pass'});
    &error(&text('change_epass', $perr)) if ($perr);
    }

# Parse custom language
if ($access{'lang'}) {
    if ($in{'lang_def'}) {
        $user->{'lang'} = undef;
        }
    else {
        $user->{'lang'} = $in{'lang'};
        }
    }

# Parse custom theme and possibly overlay
my ($newoverlay, $newtheme);
if ($access{'theme'}) {
    if ($in{'theme_def'}) {
        $user->{'theme'} = undef;
        }
    else {
        $user->{'theme'} = $in{'theme'};
        }
    $newtheme = $user->{'theme'};
    if (!defined($newtheme)) {
        $newtheme = $gconfig{'theme'};
        }

    # Overlay
    if (!$in{'overlay'}) {
        $newoverlay = undef;
        $user->{'overlay'} = undef;
        }
    else {
        $newoverlay = $in{'overlay'};
        $user->{'theme'} || &error($text{'change_eoverlay'});
        my %oinfo = &get_theme_info($in{'overlay'});
        if ($oinfo{'overlays'} &&
            &indexof($user->{'theme'},
                 split(/\s+/, $oinfo{'overlays'})) < 0) {
            &error($text{'change_eoverlay2'});
            }
        $user->{'overlay'} = $in{'overlay'};
        }
    }

# Parse password change
if ($access{'pass'} && &can_change_pass($user) && !$in{'pass_def'}) {
    $user->{'pass'} = &acl::encrypt_password($in{'pass'});
    $user->{'temppass'} = 0;
    }

&ui_print_unbuffered_header(undef, $text{'change_title'}, "");

print "$text{'change_user'}<br>\n";
&acl::modify_user($user->{'name'}, $user);
print "$text{'change_done'}<p>\n";

print "$text{'change_restart'}<br>\n";
&reload_miniserv();
print "$text{'change_done'}<p>\n";

if ($access{'theme'} &&
    ($newtheme ne $oldtheme || $newoverlay ne $oldoverlay)) {
    print "$text{'change_redirect'}<br>\n";
    print &js_redirect("/", "top");
    print "$text{'change_done'}<p>\n";
    }

&ui_print_footer("/", $text{'index'});


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