Skip to content

Instantly share code, notes, and snippets.

@davehardy20
Last active August 29, 2015 14:17
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save davehardy20/cfd93fbd9e09999352dd to your computer and use it in GitHub Desktop.
Save davehardy20/cfd93fbd9e09999352dd to your computer and use it in GitHub Desktop.
Remove-Module PowerView -ErrorAction SilentlyContinue
Remove-Module PowerUp -ErrorAction SilentlyContinue
$webclient = New-Object System.Net.WebClient
$url = "https://github.com/Veil-Framework/PowerTools/archive/master.zip"
$file = "$($env:TEMP)\PowerTools.zip"
$webclient.DownloadFile($url,$file)
#Unblock-File -Path $file
$targetondisk = "$([System.Environment]::GetFolderPath('MyDocuments'))\WindowsPowerShell\Modules"
New-Item -ItemType Directory -Force -Path $targetondisk | out-null
$shell_app=new-object -com shell.application
$zip_file = $shell_app.namespace($file)
$destination = $shell_app.namespace($targetondisk)
$destination.Copyhere($zip_file.items(), 0x10)
Rename-Item -Path ($targetondisk+"\PowerTools-master") -NewName "PowerTools" -Force
set-location $targetondisk"\PowerTools\PowerView"; Import-Module .\PowerView
set-location $targetondisk"\PowerTools\PowerUp"; Import-Module .\PowerUp
set-location $targetondisk"\PowerTools\PewPewPew"; Import-Module .\Invoke-MassCommand.ps1, .\Invoke-MassMimikatz.ps1, .\Invoke-MassSearch.ps1, .\Invoke-MassTemplate.ps1, .\Invoke-MassTokens.ps1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment