mirror of
https://github.com/rapid7/metasploit-framework
synced 2024-11-12 11:52:01 +01:00
expose linux/osx process rename functionality
This commit is contained in:
parent
03d1523d43
commit
df633247bb
@ -66,6 +66,10 @@ module Msf
|
||||
OptInt.new(
|
||||
'SessionCommunicationTimeout',
|
||||
[ false, 'The number of seconds of no activity before this session should be killed', TIMEOUT_COMMS]
|
||||
),
|
||||
OptString.new(
|
||||
'PayloadProcessCommandLine',
|
||||
[ false, 'The displayed command line that will be used by the payload', '']
|
||||
)
|
||||
],
|
||||
self.class
|
||||
|
@ -65,6 +65,12 @@ module Msf
|
||||
end
|
||||
|
||||
def generate_config(opts={})
|
||||
ds = opts[:datastore] || datastore
|
||||
|
||||
if ds['PayloadProcessCommandLine'] != ''
|
||||
opts[:name] ||= ds['PayloadProcessCommandLine']
|
||||
end
|
||||
|
||||
opts[:uuid] ||= generate_payload_uuid
|
||||
|
||||
case opts[:scheme]
|
||||
@ -85,7 +91,7 @@ module Msf
|
||||
end
|
||||
opts[:session_guid] = Base64.encode64(guid).strip
|
||||
|
||||
opts.slice(:uuid, :session_guid, :uri, :debug, :log_file)
|
||||
opts.slice(:uuid, :session_guid, :uri, :debug, :log_file, :name)
|
||||
end
|
||||
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user