Esempio n. 1
0
 /**
  * Executes file checking
  *
  * Performs the actual execution of a file scan after determining that such an execution is needed.
  *
  * @since 4.0.0
  *
  * @static
  *
  * @param bool $scheduled_call [optional] true if this is an automatic check
  * @param bool $return_data    [optional] whether to return a data array (true) or not (false)
  *
  * @return mixed
  */
 public static function run_scan($scheduled_call = true, $return_data = false)
 {
     if (!self::$instance) {
         self::$instance = new self();
     }
     return self::$instance->execute_file_check($scheduled_call, $return_data);
 }
Esempio n. 2
0
 public function handle_ajax_request($data)
 {
     if ('one-time-scan' === $data['method']) {
         require_once dirname(__FILE__) . '/scanner.php';
         ITSEC_Response::set_response(ITSEC_File_Change_Scanner::run_scan(false));
     } else {
         if ('get-filetree-data' === $data['method']) {
             ITSEC_Response::set_response($this->get_filetree_data($data));
         }
     }
 }
Esempio n. 3
0
 public function run_scan()
 {
     require_once dirname(__FILE__) . '/scanner.php';
     return ITSEC_File_Change_Scanner::run_scan();
 }
 /**
  * Functionaly to execute when calling the verb
  *
  * Functionality to execute when calling this verb VIA Sync.
  *
  * @since 4.0.0
  *
  * @return array response indicating result of the file scan
  */
 public function run($arguments)
 {
     require_once dirname(__FILE__) . '/scanner.php';
     return ITSEC_File_Change_Scanner::run_scan(false, true);
 }