use RHOSTS in many places where we used RHOST
parent
b9e0b628ef
commit
b456cd2c8c
|
@ -42,7 +42,7 @@ module Msf
|
|||
|
||||
# @return [OptAddress]
|
||||
def self.RHOST(default=nil, required=true, desc="The target address")
|
||||
Msf::OptAddress.new(__method__.to_s, [ required, desc, default ])
|
||||
Msf::OptAddressRange.new('RHOSTS', [ required, desc, default ], aliases: [ 'RHOST' ])
|
||||
end
|
||||
|
||||
# @return [OptPort]
|
||||
|
|
|
@ -1590,23 +1590,6 @@ class Core
|
|||
end
|
||||
end
|
||||
|
||||
# Warn when setting RHOST option for module which expects RHOSTS
|
||||
if args.first.upcase.eql?('RHOST')
|
||||
mod = active_module
|
||||
unless mod.nil?
|
||||
if !mod.options.include?('RHOST') && mod.options.include?('RHOSTS')
|
||||
warn_rhost = false
|
||||
if mod.exploit? && mod.datastore['PAYLOAD']
|
||||
p = framework.payloads.create(mod.datastore['PAYLOAD'])
|
||||
warn_rhost = (p && !p.options.include?('RHOST'))
|
||||
else
|
||||
warn_rhost = true
|
||||
end
|
||||
print_warning("RHOST is not a valid option for this module. Did you mean RHOSTS?") if warn_rhost
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
# Set the supplied name to the supplied value
|
||||
name = args[0]
|
||||
value = args[1, args.length-1].join(' ')
|
||||
|
|
Loading…
Reference in New Issue