mirror of
https://github.com/searxng/searxng.git
synced 2025-08-21 19:26:47 +02:00
[fix] limiter: trusted proxies doc-string (#5104)
This commit is contained in:
parent
ce8929cabe
commit
935f3fe332
1 changed files with 4 additions and 4 deletions
|
@ -20,15 +20,15 @@ if t.TYPE_CHECKING:
|
||||||
|
|
||||||
|
|
||||||
class ProxyFix:
|
class ProxyFix:
|
||||||
"""A middleware like the ProxyFix_ class, where the `x_for` argument is
|
"""A middleware like the ProxyFix_ class, where the ``x_for`` argument is
|
||||||
replaced by a method that determines the number of trusted proxies via
|
replaced by a method that determines the number of trusted proxies via the
|
||||||
the `botdetection.trusted_proxies` setting.
|
``botdetection.trusted_proxies`` setting.
|
||||||
|
|
||||||
.. sidebar:: :py:obj:`flask.Request.remote_addr`
|
.. sidebar:: :py:obj:`flask.Request.remote_addr`
|
||||||
|
|
||||||
SearXNG uses Werkzeug's ProxyFix_ (with it default ``x_for=1``).
|
SearXNG uses Werkzeug's ProxyFix_ (with it default ``x_for=1``).
|
||||||
|
|
||||||
The remote IP (py:obj:`flask.Request.remote_addr`) of the request is taken
|
The remote IP (:py:obj:`flask.Request.remote_addr`) of the request is taken
|
||||||
from (first match):
|
from (first match):
|
||||||
|
|
||||||
- X-Forwarded-For_: If the header is set, the first untrusted IP that comes
|
- X-Forwarded-For_: If the header is set, the first untrusted IP that comes
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue