Skip to content

Instantly share code, notes, and snippets.

@PolarBearGod
Last active March 13, 2018 18:28
Show Gist options
  • Save PolarBearGod/93f9795aef36388060f173aaf619d8d3 to your computer and use it in GitHub Desktop.
Save PolarBearGod/93f9795aef36388060f173aaf619d8d3 to your computer and use it in GitHub Desktop.
$client=new-object System.Net.WebClient;
$client.DownloadFile("https://live.sysinternals.com/autorunsc.exe","c:\windows\temp\autoruns.exe");
(New-Object -com Shell.Application).ShellExecute("powershell.exe", "-windowstyle hidden -Command c:\windows\temp\autoruns.exe -a * -c -h -s -t -nobanner > C:\windows\temp\$env:ComputerName-autoruns.csv");
sleep(100)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment