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


Viewing file:     save_soa.cgi (2.44 KB)      -rwxr-xr-x
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
#!/usr/bin/perl
# save_soa.cgi
# Save changes to an SOA record

require './bind8-lib.pl';
&ReadParse();
&error_setup($text{'master_err2'});
$zone = &get_zone_name_or_error($in{'zone'}, $in{'view'});
$dom = $zone->{'name'};
&can_edit_zone($zone) ||
    &error($text{'master_ecannot'});
$access{'ro'} && &error($text{'master_ero'});
$access{'params'} || &error($text{'master_esoacannot'});

# Get the SOA and file
@recs = &read_zone_file($zone->{'file'}, $dom);
foreach $r (@recs) {
    $soa = $r if ($r->{'type'} eq "SOA");
    }
$soa || &error($text{'master_esoagone'});
$file = $soa->{'file'};

# check inputs
&valdnsname($in{'master'}, 0, $in{'origin'}) ||
    &error(&text('master_emaster', $in{'master'}));
&valemail($in{'email'}) ||
    &error(&text('master_eemail', $in{'email'}));
$in{'refresh'} =~ /^\d+$/ ||
    &error(&text('master_erefresh', $in{'refresh'}));
$in{'retry'} =~ /^\d+$/ ||
    &error(&text('master_eretry', $in{'retry'}));
$in{'expiry'} =~ /^\d+$/ ||
    &error(&text('master_eexpiry', $in{'expiry'}));
$in{'minimum'} =~ /^\d+$/ ||
    &error(&text('master_eminimum', $in{'minimum'}));
if ($in{'email'} =~ /\@/) {
    $in{'email'} = &email_to_dotted($in{'email'});
    }
$in{'defttl_def'} || $in{'defttl'} =~ /^\d+$/ ||
    &error(&text('master_edefttl', $in{'defttl'}));

&lock_file(&make_chroot($file));
@recs = &read_zone_file($file, $in{'origin'});
$old = $recs[$in{'num'}];
# already set serial if no acl allow it to update or update is disabled
$serial = $old->{'values'}->[2];
if ($config{'updserial_on'}) {
    # automatically handle serial numbers ?
    $serial = &compute_serial($old->{'values'}->[2]);
    }
else {
    $in{'serial'} =~ /^\d+$/ || &error($text{'master_eserial'});
    $serial = $in{'serial'};
    }
$vals = "$in{'master'} $in{'email'} (\n".
    "\t\t\t$serial\n".
    "\t\t\t$in{'refresh'}$in{'refunit'}\n".
    "\t\t\t$in{'retry'}$in{'retunit'}\n".
    "\t\t\t$in{'expiry'}$in{'expunit'}\n".
    "\t\t\t$in{'minimum'}$in{'minunit'} )";
&modify_record($file, $old, $old->{'name'}, $old->{'ttl'},
           $old->{'class'}, "SOA", $vals);

($defttl) = grep { $_->{'defttl'} } @recs;
if (!$defttl && !$in{'defttl_def'}) {
    &create_defttl($file, $in{'defttl'}.$in{'defttlunit'});
    }
elsif ($defttl && !$in{'defttl_def'}) {
    &modify_defttl($file, $defttl, $in{'defttl'}.$in{'defttlunit'});
    }
elsif ($defttl && $in{'defttl_def'}) {
    &delete_defttl($file, $defttl);
    }

&unlock_file(&make_chroot($file));
&webmin_log("soa", undef, $in{'origin'}, \%in);
&redirect("edit_master.cgi?zone=$in{'zone'}&view=$in{'view'}");


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