From c342726ad4ccbb90b8ff29f1cc1c89f9f7e8d98f Mon Sep 17 00:00:00 2001 From: Yohan Boniface Date: Fri, 26 Apr 2019 13:48:55 +0200 Subject: Allow to control RATES_LIMIT from configuration (#1787) * Allow to control RATES_LIMIT from configuration * @Chocobozzz review (squash me) --- config/default.yaml | 10 ++++++++++ config/production.yaml.example | 10 ++++++++++ 2 files changed, 20 insertions(+) (limited to 'config') diff --git a/config/default.yaml b/config/default.yaml index 70b10299d..f8be23d69 100644 --- a/config/default.yaml +++ b/config/default.yaml @@ -9,6 +9,16 @@ webserver: hostname: 'localhost' port: 9000 +rates_limit: + login: + # 15 attempts in 5 min + window: 5 minutes + max: 15 + ask_send_email: + # 3 attempts in 5 min + window: 5 minutes + max: 3 + # Proxies to trust to get real client IP # If you run PeerTube just behind a local proxy (nginx), keep 'loopback' # If you run PeerTube behind a remote proxy, add the proxy IP address (or subnet) diff --git a/config/production.yaml.example b/config/production.yaml.example index 06baaf7d4..f1f0f12d1 100644 --- a/config/production.yaml.example +++ b/config/production.yaml.example @@ -8,6 +8,16 @@ webserver: hostname: 'example.com' port: 443 +rates_limit: + login: + # 15 attempts in 5 min + window: 5 minutes + max: 15 + ask_send_email: + # 3 attempts in 5 min + window: 5 minutes + max: 3 + # Proxies to trust to get real client IP # If you run PeerTube just behind a local proxy (nginx), keep 'loopback' # If you run PeerTube behind a remote proxy, add the proxy IP address (or subnet) -- cgit v1.2.3