We all know that in Windows + IIS6.0, if there is a directory like xxx. asp in the directory structure, all files under this directory will be parsed as asp regardless of the extension. We generally call this vulnerability windows2003 + iis6.0 directory parsing vulnerability. But what you may not know is that the apache server also
We all know that in Windows + IIS6.0, if there is a directory like xxx. asp in the directory structure, all files under this directory will be parsed as asp regardless of the extension. We generally call this vulnerability windows2003 + iis6.0 directory parsing vulnerability. However, what you may not know is that the apache server has similar parsing vulnerabilities.
Let's start the experiment. I have built a local apache + php testing platform.
Two files: phpinfo. php phpinfo. php. a. visit phpinfo. php..
Http: // 192.168.99.110/phpinfo. php.
It can be parsed and can still be changed to another suffix.
No matter what the last suffix of the file is, as long as it is. php. * The end is parsed into a php file by the Apache server. The problem is that if apache is in mime. the types file does not have a defined extension such as x1.x2. in the case of x3, the last x3 is not defined, and it will be parsed into the second-to-last x2 defined extension. Xxx.php.rar or xxx. php.111 will be parsed to php if they are not defined in the mime. types file by default. The same is true for cgi or jsp...
If the file name is defined on the webpage of the web program, apache will still parse it as php, and we will test jpg again.
Defense method:
The apache configuration file prohibits execution of files such as. php.
Order Allow, Deny
Deny from all
Save. After apache is started, let's take a look.
OK. this is the defense method.