add ternary expression to set options
parent
6003896e3c
commit
a97cee4c91
|
@ -224,7 +224,7 @@ module Exploit::Powershell
|
||||||
def cmd_psh_payload(pay, payload_arch, opts = {})
|
def cmd_psh_payload(pay, payload_arch, opts = {})
|
||||||
%i[persist prepend_sleep exec_in_place encode_final_payload encode_inner_payload
|
%i[persist prepend_sleep exec_in_place encode_final_payload encode_inner_payload
|
||||||
remove_comspec noninteractive wrap_double_quotes no_equals method].map do |opt|
|
remove_comspec noninteractive wrap_double_quotes no_equals method].map do |opt|
|
||||||
opts[opt] ||= datastore["Powershell::#{opt}"]
|
opts[opt] = opts[opt].nil? ? datastore["Powershell::#{opt}"] : opts[opt]
|
||||||
end
|
end
|
||||||
|
|
||||||
unless opts.key? :shorten
|
unless opts.key? :shorten
|
||||||
|
|
Loading…
Reference in New Issue