mirror of
https://github.com/filebrowser/filebrowser.git
synced 2025-07-01 21:52:58 +00:00
docs: add fail2ban instructions
This commit is contained in:
parent
d1a73a8b18
commit
d644744417
34
www/docs/deployment.md
Normal file
34
www/docs/deployment.md
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
## Fail2ban
|
||||||
|
|
||||||
|
File Browser does not natively support protection against brute force attacks. Therefore, we suggest using something like [fail2ban](https://github.com/fail2ban/fail2ban), which takes care of that by tracking the logs of your File Browser instance. For more information on how fail2ban works, please refer to their [wiki](https://github.com/fail2ban/fail2ban/wiki).
|
||||||
|
|
||||||
|
### Filter Configuration
|
||||||
|
|
||||||
|
An example filter configuration targeted at matching File Browser's logs.
|
||||||
|
|
||||||
|
```ini
|
||||||
|
[INCLUDES]
|
||||||
|
before = common.conf
|
||||||
|
|
||||||
|
[Definition]
|
||||||
|
datepattern = `^%%Y\/%%m\/%%d %%H:%%M:%%S`
|
||||||
|
failregex = `\/[a-z]*\/[a-z]*: \d{3} <HOST> *`
|
||||||
|
```
|
||||||
|
|
||||||
|
### Jail Configuration
|
||||||
|
|
||||||
|
An example jail configuration. You should fill it with the path of the logs of File Browser, as well as the port where it is running at.
|
||||||
|
|
||||||
|
```ini
|
||||||
|
[filebrowser]
|
||||||
|
|
||||||
|
enabled = true
|
||||||
|
port = [your_port]
|
||||||
|
filter = filebrowser
|
||||||
|
logpath = [your_log_path]
|
||||||
|
maxretry = 10
|
||||||
|
bantime = 10m
|
||||||
|
findtime = 10m
|
||||||
|
banaction = iptables-allports
|
||||||
|
banaction_allports = iptables-allports
|
||||||
|
```
|
@ -78,8 +78,10 @@ File Browser is now up and running. Read some [first boot](#first-boot) for more
|
|||||||
|
|
||||||
Your instance is now up and running. File Browser will automatically bootstrap a database, in which the configuration and the users are stored. You can find the address in which your instance is running, as well as the randomly generated password for the user `admin`, in the console logs.
|
Your instance is now up and running. File Browser will automatically bootstrap a database, in which the configuration and the users are stored. You can find the address in which your instance is running, as well as the randomly generated password for the user `admin`, in the console logs.
|
||||||
|
|
||||||
Although this is the fastest way to bootstrap an instance, we recommend you to take a look at other possible options, by checking `config init --help` and `config set --help`, to make the installation as safe and customized as it can be.
|
|
||||||
|
|
||||||
> [!WARNING]
|
> [!WARNING]
|
||||||
>
|
>
|
||||||
> The automatically generated password for the user `admin` is only displayed once. If you fail to remember it, you will need to manually delete the database and start File Browser again.
|
> The automatically generated password for the user `admin` is only displayed once. If you fail to remember it, you will need to manually delete the database and start File Browser again.
|
||||||
|
|
||||||
|
Although this is the fastest way to bootstrap an instance, we recommend you to take a look at other possible options, by checking `config init --help` and `config set --help`, to make the installation as safe and customized as it can be.
|
||||||
|
|
||||||
|
If your goal is to have a public-facing deployment, we recommend taking a look at the [deployment](deployment.md) page for more information on how you can secure your installation.
|
||||||
|
@ -97,8 +97,10 @@ extra:
|
|||||||
|
|
||||||
nav:
|
nav:
|
||||||
- Home: index.md
|
- Home: index.md
|
||||||
- Installation: installation.md
|
- Getting Started:
|
||||||
- Configuration: configuration.md
|
- Installation: installation.md
|
||||||
|
- Configuration: configuration.md
|
||||||
|
- Deployment: deployment.md
|
||||||
- Contributing:
|
- Contributing:
|
||||||
- Contributing: contributing.md
|
- Contributing: contributing.md
|
||||||
- Code of Conduct: code-of-conduct.md
|
- Code of Conduct: code-of-conduct.md
|
||||||
|
Loading…
x
Reference in New Issue
Block a user