Home >Backend Development >PHP Tutorial >Windows下PHP的任意文件执行漏洞_PHP

Windows下PHP的任意文件执行漏洞_PHP

WBOY
WBOYOriginal
2016-06-01 12:42:29847browse

   受影响系统:
  PHP version 4.1.1 under Windows
  PHP version 4.0.4 under Windows
  
  漏洞描述:
  
  在Windows下的PHP,通过PHP.EXE,攻击者可以让任何文件作为一个php文件,即使这个文件的扩展名不是php。比如,上传一个文件,但是扩展名是mp3,txt,或者gif等等,然后要求PHP去执行它。
  例如:
  上传一个gif文件,但是实际上是一个php脚本文件,文件内容如下:
  #------------
  phpinfo();
  ?>
  #------------
  
  然后攻击者用PHP去执行:
  http://www.example.com/php/php.exe/UPLOAD_DIRECTORY/huh.gif

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn