mirror of
https://github.com/searxng/searxng.git
synced 2025-07-15 09:19:20 +02:00
[mod] document server:public_instance & remove it out of the botdetection
- the option server:public_instance lacks some documentation - the processing of this option belongs in the limiter and not in botdetection module Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
This commit is contained in:
parent
fd814aac86
commit
d13a8f6453
4 changed files with 29 additions and 9 deletions
|
@ -45,7 +45,6 @@ from ipaddress import (
|
|||
|
||||
import flask
|
||||
import werkzeug
|
||||
from searx import settings
|
||||
|
||||
from searx import redisdb
|
||||
from searx.redislib import incr_sliding_window, drop_counter
|
||||
|
@ -109,7 +108,7 @@ def filter_request(
|
|||
if c > API_MAX:
|
||||
return too_many_requests(network, "too many request in API_WINDOW")
|
||||
|
||||
if settings['server']['public_instance'] or cfg['botdetection.ip_limit.link_token']:
|
||||
if cfg['botdetection.ip_limit.link_token']:
|
||||
|
||||
suspicious = link_token.is_suspicious(network, request, True)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue