# 21 - FTP

Many FTP-servers allow anonymous users. These might be badly configured and give too much access, and anonymous access is sometimes required for exploits. Always try to log in with `anonymous:anonymous`, `anonymous:` (blank password) or `anonymous:password`!

FTP has two modes: **Binary** and **ASCII**. Keep this in mind to avoid file corruption!

### Nmap scripts:

`nmap -sV -Pn -vv -p <PORT> --script=ftp-anon,ftp-bounce,ftp-libopie,ftp-proftpd-backdoor,ftp-vsftpd-backdoor,ftp-vuln-cve2010-4221 <IP-ADDRESS>`

### Hydra brute force attack:

`hydra -s <PORT> -C <path/to/wordlist.txt> -u -f <IP-ADDRESS> ftp`


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://alexanderbittner.gitbook.io/pentest-resources/vulnerability-analysis/standard-ports-and-common-services/21-ftp.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
