Skip to content

Commit c8a29df

Browse files
committed
Merge branch '3.4' into 4.1
* 3.4: Updating security_checker.rst Update json_login_setup.rst Update the link to DynamicRouter documentation
2 parents 7fe1c0d + 10671c8 commit c8a29df

File tree

3 files changed

+13
-12
lines changed

3 files changed

+13
-12
lines changed

routing/routing_from_database.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,4 +38,4 @@ loader, e.g. for another database type or a REST API or anything else.
3838
The DynamicRouter is explained in the `Symfony CMF documentation`_.
3939

4040
.. _FrameworkExtraBundle: https://symfony.com/doc/current/bundles/SensioFrameworkExtraBundle/annotations/converters.html
41-
.. _`Symfony CMF documentation`: https://symfony.com/doc/master/cmf/book/routing.html
41+
.. _`Symfony CMF documentation`: https://symfony.com/doc/current/cmf/bundles/routing/dynamic.html

security/json_login_setup.rst

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -55,12 +55,10 @@ First, enable the JSON login under your firewall:
5555
5656
.. tip::
5757

58-
The ``check_path`` can also be a route name (but cannot have mandatory wildcards - e.g.
59-
``/login/{foo}`` where ``foo`` has no default value).
58+
The ``check_path`` can also be a route name (but cannot have mandatory
59+
wildcards - e.g. ``/login/{foo}`` where ``foo`` has no default value).
6060

61-
Now, when a request is made to the ``/login`` URL, the security system initiates
62-
the authentication process. You just need to configure a route matching this
63-
path:
61+
The next step is to configure a route in your app matching this path:
6462

6563
.. configuration-block::
6664

@@ -123,11 +121,9 @@ path:
123121
124122
return $routes;
125123
126-
When you submit a ``POST`` request to the ``/login`` URL with the following JSON
127-
document as the body, the security system intercepts the requests.
128-
It takes care of authenticating the user with the submitted username and password
129-
or triggers an error in case the authentication process fails.
130-
If the authentication is successful, the controller defined earlier will be executed.
124+
Now, when you make a ``POST`` request, with the header ``Content-Type: application/json``,
125+
to the ``/login`` URL with the following JSON document as the body, the security
126+
system intercepts the request and initiates the authentication process:
131127

132128
.. code-block:: json
133129
@@ -136,6 +132,10 @@ If the authentication is successful, the controller defined earlier will be exec
136132
"password": "MyPassword"
137133
}
138134
135+
Symfony takes care of authenticating the user with the submitted username and
136+
password or triggers an error in case the authentication process fails. If the
137+
authentication is successful, the controller defined earlier will be executed.
138+
139139
If the JSON document has a different structure, you can specify the path to
140140
access the ``username`` and ``password`` properties using the ``username_path``
141141
and ``password_path`` keys (they default respectively to ``username`` and

security/security_checker.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,8 @@ FriendsOfPHP organization.
3030

3131
The ``security:check`` command terminates with a non-zero exit code if
3232
any of your dependencies is affected by a known security vulnerability.
33-
Therefore, you can easily integrate it in your build process.
33+
This allows you to add it to your project build process and your continuous
34+
integration workflows.
3435

3536
.. tip::
3637

0 commit comments

Comments
 (0)