In this tutorial, we will first talk about available characters in PHP variables because we want to decrypt the program encrypted by Alibaba Cloud Security. Understanding the available characters in PHP variables is the primary condition for decryption, go directly to the topic and talk about the naming rules of php variables. Baidu will take the following measures:
(1) PHP variable names are case sensitive;
(2) the variable name must start with the dollar sign $;
(3) a variable name can start with an underscore;
(4) the variable name cannot start with a number.
In fact, the naming rules for all programming are similar:
1. the first character of the variable is preferably a letter or _. it cannot start with a number.
2. the second character can start with a number, letter ,_
Well, that's almost the case, but this is not the point we're going to focus on.
Today, let's talk about the available characters of PHP variables, not just numbers, letters,.
A friend sent me a shell on QQ a few days ago. it was encrypted and garbled, but there was a comment on it, which is called "shield encryption.
Some Uncommon Knowledge points are used, the most obvious of which is the variable name. so let's start with the variable today.
Of course, I did not find any authoritative materials on the Internet to strongly illustrate the available characters of PHP variable names, so I can only test it myself. (Poor English, no good evidence for Google)
First, let's take a look at the method I used. (if you have a better method, I hope to share it with you .)
The code is as follows:
If ($ _ POST ){
$ Chr = chr ($ _ POST ['chr']);
Eval ('$'. $ chr. "= 1 ;");
Echo 'OK ';
Exit;
}
?>
Test