Skip to content
This repository was archived by the owner on Sep 16, 2021. It is now read-only.

Commit 722d7dc

Browse files
committed
make comment on limit_candidates a caution
1 parent 9ea2670 commit 722d7dc

File tree

3 files changed

+8
-9
lines changed

3 files changed

+8
-9
lines changed

bundles/routing/dynamic.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,7 @@ get an error if Sonata becomes unavailable.
293293
Sonata admin is using the ``content_basepath`` to show the tree of content to
294294
select the route target.
295295

296-
The root path to add Routes defaults to the first entry in ``route_basepaths``
296+
The root path to add Routes defaults to the first entry in ``route_basepaths``,
297297
but you can overwrite this with the ``admin_basepath`` if you need a different
298298
base path.
299299

bundles/simple_cms/rendering.rst

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,6 @@ When you need specific settings for a single page, you can call
1010
``setDefault()`` for the key ``_template`` or ``_controller`` default in the
1111
page instance.
1212

13-
Alternatively one can
14-
configure the template and controller also via the SimpleCmsBundle
15-
:ref:`routing configuration <config-simple-cms-routing>`.
16-
1713
A simple example for such a template could look like this:
1814

1915
.. configuration-block::

reference/configuration/routing.rst

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -527,11 +527,14 @@ limit_candidates
527527
With this flag you can tune the routing behaviour when using the dynamic
528528
pattern part of routes stored in the database. If you do never use the variable
529529
pattern field of the Route model, you can set this to 1 as a small performance
530-
optimization.
530+
optimization. If you have very complex URLs with patterns, you might need to
531+
increase the limit.
531532

532-
If you have very complex URLs with patterns, you might need to increase the
533-
limit, but this will expose your site to load attacks with URLs with lots of
534-
slashes in them.
533+
.. caution::
534+
535+
Setting this to a higher makes your site more vulnerable to load attacks
536+
when someone visits your site with URLs with lots of slashes in them, since
537+
every slash will lead to a document being tried to be loaded.
535538

536539
match_implicit_locale
537540
~~~~~~~~~~~~~~~~~~~~~

0 commit comments

Comments
 (0)