403Webshell
Server IP : 103.234.187.230  /  Your IP : 216.73.216.216
Web Server : Apache
System : Linux lserver42043-ind.megavelocity.net 3.10.0-1160.108.1.el7.x86_64 #1 SMP Thu Jan 25 16:17:31 UTC 2024 x86_64
User : apache ( 48)
PHP Version : 7.4.33
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /var/www/html/b2bzend/library/Catabatic/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /var/www/html/b2bzend/library/Catabatic/ValidateAdmin.php
<?php

class Catabatic_ValidateAdmin extends Catabatic_ValidateCustomer {

    protected $_actionName = null;
    protected $_controllerName = null;
    protected $_moduleName = null;
    protected $_userRole = null;

    public function init() {
        $sessionCheck = new Zend_Session_Namespace('sessionLogin_user');
        parent::init();
        if ((Travel_Model_AdminAuth::getIdentity()->IsActive != 1 && Travel_Model_AdminAuth::getIdentity()->UserAccessLevelType == 0) || empty($sessionCheck->params3)) {
            $redirector = Zend_Controller_Action_HelperBroker::getStaticHelper('redirector');
            $redirector->gotoUrl('admin/index/logout');
            return;
        } else {
            $this->_actionName = Zend_Controller_Front::getInstance()->getRequest()->getActionName();
            $this->_controllerName = Zend_Controller_Front::getInstance()->getRequest()->getControllerName();
            $this->_moduleName = Zend_Controller_Front::getInstance()->getRequest()->getModuleName();
            $this->_userRole = Travel_Model_AdminAuth::getIdentity()->UserRole;
        }
    }

    function preDispatch() {
        $acl = new Zend_Acl();
        ######### Role Definitions Start ###################
        $acl->addRole(new Zend_Acl_Role(70));
        $acl->addRole(new Zend_Acl_Role(1));
        $acl->addRole(new Zend_Acl_Role(2));
        ######### Role Definitions End #####################
        ######### Resource Definitions Start ###############
        $acl->add(new Zend_Acl_Resource('cityprofiling'));
        $acl->add(new Zend_Acl_Resource('admin'));
        $acl->add(new Zend_Acl_Resource('insurance'));
        $acl->add(new Zend_Acl_Resource('finance'));
        $acl->add(new Zend_Acl_Resource('subscription'));
        // $acl->add(new Zend_Acl_Resource('city-api-map'));
        $acl->allow(1, array('cityprofiling', 'admin', 'insurance', 'finance','subscription'));
        $acl->allow(2, array('admin'));
        $acl->allow(70, array('admin'));
        ######### Privileges Definitions End ##############
        ######### setup acl in the registry ################
        Zend_Registry::set('acl', $acl);
        ######### Check Permissions   #####################
        if (!$acl->isAllowed($this->_userRole, $this->_moduleName, $this->_controllerName)) {
            $redirector = Zend_Controller_Action_HelperBroker::getStaticHelper('redirector');
            $redirector->gotoUrl('admin/index/logout');
            return;
        }
    }

}

Youez - 2016 - github.com/yon3zu
LinuXploit