Land #6889, check #nil? and #empty? instead of #empty?

bug/bundler_fix
wchen-r7 2016-05-19 19:23:04 -05:00
commit 506356e15d
No known key found for this signature in database
GPG Key ID: 2384DB4EF06F730B
6 changed files with 9 additions and 10 deletions

View File

@ -133,7 +133,7 @@ class MetasploitModule < Msf::Exploit::Remote
end
def exploit
if not datastore['CMD'].empty?
unless datastore['CMD'].blank?
print_status("Executing user supplied command")
execute_command(datastore['CMD'])
return

View File

@ -186,7 +186,7 @@ class MetasploitModule < Msf::Exploit::Remote
end
def exploit
if not datastore['CMD'].empty?
unless datastore['CMD'].blank?
print_status("Executing user supplied command")
execute_command(datastore['CMD'])
return

View File

@ -149,7 +149,7 @@ class MetasploitModule < Msf::Exploit::Remote
def exploit
if not datastore['CMD'].empty?
unless datastore['CMD'].blank?
print_status("Executing command '#{datastore['CMD']}'")
execute_command(datastore['CMD'])
return
@ -160,7 +160,7 @@ class MetasploitModule < Msf::Exploit::Remote
windows_stager
else
fail_with(Failure::Unknown, 'Target not supported.')
end
end
handler

View File

@ -57,7 +57,7 @@ class MetasploitModule < Msf::Exploit::Remote
exe_fname = rand_text_alphanumeric(4+rand(4)) + ".exe"
print_status("Sending request to #{datastore['RHOST']}:#{datastore['RPORT']}")
execute_cmdstager({ :temp => '.' })
execute_cmdstager({ :temp => '.', :cgifname => exe_fname })
@payload_exe = generate_payload_exe
print_status("Attempting to execute the payload...")
@ -92,8 +92,7 @@ class MetasploitModule < Msf::Exploit::Remote
end
def exploit
if not datastore['CMD'].empty?
unless datastore['CMD'].blank?
print_status("Executing command '#{datastore['CMD']}'")
execute_command(datastore['CMD'])
return
@ -104,7 +103,7 @@ class MetasploitModule < Msf::Exploit::Remote
windows_stager
else
fail_with(Failure::Unknown, 'Target not supported.')
end
end
handler

View File

@ -110,7 +110,7 @@ class MetasploitModule < Msf::Exploit::Remote
def exploit
if not datastore['CMD'].empty?
unless datastore['CMD'].blank?
print_status("Executing command '#{datastore['CMD']}'")
execute_command(datastore['CMD'])
return

View File

@ -93,7 +93,7 @@ class MetasploitModule < Msf::Exploit::Remote
def exploit
if not datastore['CMD'].empty?
unless datastore['CMD'].blank?
print_status("Executing command '#{datastore['CMD']}'")
execute_command(datastore['CMD'])
return