8000 feature #13704 [Security] Added docs about the authenticator-based Se… · symfony/symfony-docs@ce95d60 · GitHub
[go: up one dir, main page]

Skip to content

Commit ce95d60

Browse files
committed
feature #13704 [Security] Added docs about the authenticator-based Security system (wouterj)
This PR was squashed before being merged into the 5.1 branch. Discussion ---------- [Security] Added docs about the authenticator-based Security system As the new system is experimental, I think it's best to not update the main documentation of Security yet (also, the main guide isn't really affected by the new system - except from the removal of anonymous). This can be done once we deprecate the old system (in 5.3 or 5.4). I do however think we should link more to this article, as I want to push people to use it. What do you think about adding a `.. tip::` in: * [x] `security/guard_authentication` & `security/form_login_setup` * [ ] <s>`security/custom_authentication_provider` (replace the one to Guard)</s> * [x] `security` (at the start, as a "hey, please start by doing `enable_authenticator_manager: true`") Fixes #13575 Commits ------- bdb5271 [Security] Added docs about the authenticator-based Security system
2 parents 97a96c8 + bdb5271 commit ce95d60

File tree

3 files changed

+548
-0
lines changed

3 files changed

+548
-0
lines changed

security.rst

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,49 @@ install the security feature before using it:
3737
3838
$ composer require symfony/security-bundle
3939
40+
41+
.. tip::
42+
43+
A :doc:`new experimental Security </security/experimental_authenticators>`
44+
was introduced in Symfony 5.1, which will eventually replace security in
45+
Symfony 6.0. This system is almost fully backwards compatible with the
46+
current Symfony security, add this line to your security configuration to start
47+
using it:
48+
49+
.. configuration-block::
50+
51+
.. code-block:: yaml
52+
53+
# config/packages/security.yaml
54+
security:
55+
enable_authenticator_manager: true
56+
# ...
57+
58+
.. code-block:: xml
59+
60+
<!-- config/packages/security.xml -->
61+
<?xml version="1.0" encoding="UTF-8"?>
62+
<srv:container xmlns="http://symfony.com/schema/dic/security"
63+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
64+
xmlns:srv="http://symfony.com/schema/dic/services"
65+
xsi:schemaLocation="http://symfony.com/schema/dic/services
66+
https://symfony.com/schema/dic/services/services-1.0.xsd
67+
http://symfony.com/schema/dic/security
68+
https://symfony.com/schema/dic/security/security-1.0.xsd">
69+
70+
<config enable-authenticator-manager="true">
71+
<!-- ... -->
72+
</config>
73+
</srv:container>
74+
75+
.. code-block:: php
76+
77+
// config/packages/security.php
78+
$container->loadFromExtension('security', [
79+
'enable_authenticator_manager' => true,
80+
// ...
81+
]);
82+
4083
.. _initial-security-yml-setup-authentication:
4184
.. _initial-security-yaml-setup-authentication:
4285
.. _create-user-class:
@@ -1121,6 +1164,7 @@ Authentication (Identifying/Logging in the User)
11211164
.. toctree::
11221165
:maxdepth: 1
11231166

1167+
security/experimental_authenticators
11241168
security/form_login_setup
11251169
security/reset_password
11261170
security/json_login_setup

0 commit comments

Comments
 (0)
0