!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/backup-config/   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.cgi (3.33 KB)      -rwxr-xr-x
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
#!/usr/bin/perl
# Create, update or delete a scheduled backup

use strict;
use warnings;
require './backup-config-lib.pl';
our (%in, %text, $cron_cmd, $module_name);
&ReadParse();

# Find the backup job
my ($job, $backup);
if (!$in{'new'}) {
    $backup = &get_backup($in{'id'});
    $job = &find_cron_job($backup);
    }
else {
    $backup = { };
    }

if ($in{'delete'}) {
    # Delete the backup
    &delete_backup($backup);
    if ($job) {
        &lock_file(&cron::cron_file($job));
        &cron::delete_cron_job($job);
        &unlock_file(&cron::cron_file($job));
        }
    }
else {
    # Validate inputs
    &error_setup($text{'save_err'});
    my @mods = split(/\0/, $in{'mods'});
    $backup->{'mods'} = join(" ", @mods);
    $backup->{'dest'} = &parse_backup_destination("dest", \%in);
    &cron::parse_times_input($backup, \%in);
    $backup->{'emode'} = $in{'emode'};
    $backup->{'email'} = $in{'email'};
    $backup->{'pre'} = $in{'pre'};
    $backup->{'post'} = $in{'post'};
    $backup->{'sched'} = $in{'sched'};
    ($backup->{'configfile'}, $backup->{'nofiles'}, $backup->{'others'}) =
        &parse_backup_what("what", \%in);
    @mods || ($backup->{'nofiles'} && !$backup->{'configfile'}) ||
        &error($text{'save_emods'});

    # Save or create
    &save_backup($backup);
    if ($job) {
        &lock_file(&cron::cron_file($job));
        &cron::delete_cron_job($job);
        }
    if ($in{'sched'}) {
        &cron::create_wrapper($cron_cmd, $module_name, "backup.pl");
        $job = { 'user' => 'root',
             'command' => "$cron_cmd $backup->{'id'}",
             'active' => 1,
             'mins' => $backup->{'mins'},
             'hours' => $backup->{'hours'},
             'days' => $backup->{'days'},
             'months' => $backup->{'months'},
             'weekdays' => $backup->{'weekdays'},
             'special' => $backup->{'special'} };
        &lock_file(&cron::cron_file($job));
        &cron::create_cron_job($job);
        }
    &unlock_file(&cron::cron_file($job)) if ($job);
    }
&webmin_log($in{'new'} ? 'create' : $in{'delete'} ? 'delete' : 'modify',
        'backup', $backup->{'dest'}, $backup);

if ($in{'run'}) {
    # Execute the backup now
    &ui_print_unbuffered_header(undef, $text{'run_title'}, "");

    # Run the pre-backup command, if any
    my $err;
    if ($backup->{'pre'} =~ /\S/) {
        my $preout = &backquote_command(
            "($backup->{'pre'}) 2>&1 </dev/null");
        print &text('email_pre',
            "<tt>".&html_escape($backup->{'pre'})."</tt>")."<br>\n".
            "<pre>".&html_escape($preout)."</pre>\n";
        if ($?) {
            $err = $text{'email_prefailed'};
            }
        }

    my @mods = split(/\s+/, $backup->{'mods'});
    my $nice = &nice_dest($backup->{'dest'}, 1);
    if (!$err) {
        print &text('run_doing', scalar(@mods),
                "<tt>$nice</tt>"),"<br>\n";
        my $size;
        $err = &execute_backup(
            \@mods, $backup->{'dest'}, \$size, undef,
            $backup->{'configfile'}, $backup->{'nofiles'},
            [ split(/\t+/, $backup->{'others'}) ]);
        }
    if ($err) {
        print "<pre>$err</pre>";
        print "$text{'run_failed'}<p>\n";
        }
    else {
        print "$text{'run_ok'}<p>\n";
        }

    # Run the post-backup command, if any
    if (!$err && $backup->{'post'} =~ /\S/) {
        my $postout = &backquote_command(
            "($backup->{'post'}) 2>&1 </dev/null");
        print &text('email_post',
              "<tt>".&html_escape($backup->{'post'})."</tt>")."<br>\n".
              "<pre>".&html_escape($postout)."</pre>\n";
        }

    &webmin_log("run", "backup", $backup->{'dest'}, $backup);
    &ui_print_footer("edit.cgi?id=$in{'id'}", $text{'edit_return'},
             "index.cgi?mode=sched", $text{'index_return'});
    }
else {
    &redirect("index.cgi?mode=sched");
    }



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