Land #8991, post/windows/manage/persistence_exe: fix service creation

bug/bundler_fix
Brent Cook 2017-10-05 17:04:58 -05:00
commit 4a745bd2cc
No known key found for this signature in database
GPG Key ID: 1FFAA0B24B708F96
1 changed files with 1 additions and 1 deletions

View File

@ -140,7 +140,7 @@ class MetasploitModule < Msf::Post
print_status("Installing as service..")
nam = Rex::Text.rand_text_alpha(rand(8) + 8)
print_status("Creating service #{nam}")
service_create(nam, nam, "cmd /c \"#{script_on_target}\"")
service_create(nam, :path=>"cmd /c \"#{script_on_target}\"")
@clean_up_rc << "execute -H -f sc -a \"delete #{nam}\"\n"
else
print_error("Insufficient privileges to create service")