From e145728b14a6db6fc238106d5e51ef3afce5a01b Mon Sep 17 00:00:00 2001 From: Hugo Clergue <60431933+Hugo-pro404@users.noreply.github.com> Date: Wed, 22 Mar 2023 14:06:43 +0100 Subject: [PATCH] Update access_control.rst I've just corrected some description of the "Why ?" column of the table, because the ``access_control`` used didn't match their description, based on their numbers. --- security/access_control.rst | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/security/access_control.rst b/security/access_control.rst index 680c79b0840..81aae70c602 100644 --- a/security/access_control.rst +++ b/security/access_control.rst @@ -150,15 +150,16 @@ if ``ip``, ``port``, ``host`` or ``method`` are not specified for an entry, that +-----------------+-------------+-------------+-------------+------------+--------------------------------+-------------------------------------------------------------+ | ``/admin/user`` | 127.0.0.1 | 8080 | symfony.com | GET | rule #1 (``ROLE_USER_PORT``) | The ``path``, ``ip`` and ``port`` match. | +-----------------+-------------+-------------+-------------+------------+--------------------------------+-------------------------------------------------------------+ -| ``/admin/user`` | 168.0.0.1 | 80 | symfony.com | GET | rule #3 (``ROLE_USER_HOST``) | The ``ip`` doesn't match the first rule, so the second | -| | | | | | | rule (which matches) is used. | +| ``/admin/user`` | 168.0.0.1 | 80 | symfony.com | GET | rule #3 (``ROLE_USER_HOST``) | The ``ip`` doesn't match neither the first rule nor the | +| | | | | | | second rule. So the third rule (which matches) is used. | +-----------------+-------------+-------------+-------------+------------+--------------------------------+-------------------------------------------------------------+ -| ``/admin/user`` | 168.0.0.1 | 80 | symfony.com | POST | rule #3 (``ROLE_USER_HOST``) | The second rule still matches. This would also match the | -| | | | | | | third rule (``ROLE_USER_METHOD``), but only the **first** | +| ``/admin/user`` | 168.0.0.1 | 80 | symfony.com | POST | rule #3 (``ROLE_USER_HOST``) | The third rule still matches. This would also match the | +| | | | | | | fourth rule (``ROLE_USER_METHOD``), but only the **first** | | | | | | | | matched ``access_control`` is used. | +-----------------+-------------+-------------+-------------+------------+--------------------------------+-------------------------------------------------------------+ -| ``/admin/user`` | 168.0.0.1 | 80 | example.com | POST | rule #4 (``ROLE_USER_METHOD``) | The ``ip`` and ``host`` don't match the first two entries, | -| | | | | | | but the third - ``ROLE_USER_METHOD`` - matches and is used. | +| ``/admin/user`` | 168.0.0.1 | 80 | example.com | POST | rule #4 (``ROLE_USER_METHOD``) | The ``ip`` and ``host`` don't match the first three | +| | | | | | | entries, but the fourth - ``ROLE_USER_METHOD`` - matches | +| | | | | | | and is used. | +-----------------+-------------+-------------+-------------+------------+--------------------------------+-------------------------------------------------------------+ | ``/foo`` | 127.0.0.1 | 80 | symfony.com | POST | matches no entries | This doesn't match any ``access_control`` rules, since its | | | | | | | | URI doesn't match any of the ``path`` values. |