|
4 | 4 | How to load Security Users from the Database (the Entity Provider)
|
5 | 5 | ==================================================================
|
6 | 6 |
|
7 |
| -The security layer is one of the most smart tools of Symfony. It handles two |
| 7 | +The security layer is one of the smartest tools of Symfony. It handles two |
8 | 8 | things: the authentication and the authorization processes. Although it seems
|
9 |
| -a bit quiet complex to understand how everything works internally, this security |
| 9 | +quiet complex to understand how everything works internally, this security |
10 | 10 | system is very flexible and allows you to plug your application to any
|
11 | 11 | authentication backends like an Active Directory, an OAuth server or a database.
|
12 | 12 |
|
@@ -35,7 +35,7 @@ For the purpose of this cookbook, the ``AcmeUserBundle`` bundle contains a
|
35 | 35 | string assigned to the user and the ``isActive`` value tells whether or not the
|
36 | 36 | user account is active.
|
37 | 37 |
|
38 |
| -To make it shorter, the getter and setter method for each have been removed to |
| 38 | +To make it shorter, the getter and setter methods for each have been removed to |
39 | 39 | focus on the most important methods that come from the `UserInterface`_.
|
40 | 40 |
|
41 | 41 | .. code-block:: php
|
@@ -157,15 +157,15 @@ Below is an export of my ``User`` table from MySQL.
|
157 | 157 | 4 rows in set (0.00 sec)
|
158 | 158 |
|
159 | 159 | The database now contains four users with different roles and statuses. The next
|
160 |
| -part will focus on how to authenticate one these users thanks to the Doctrine |
| 160 | +part will focus on how to authenticate one of these users thanks to the Doctrine |
161 | 161 | entity user provider and a couple of lines of configuration.
|
162 | 162 |
|
163 | 163 | Authenticating Someone Against a Database
|
164 | 164 | -----------------------------------------
|
165 | 165 |
|
166 | 166 | Authenticating a Doctrine user against the database with the Symfony security
|
167 | 167 | layer is a piece of cake. Everything resides in the configuration of the
|
168 |
| -``app/config/security.yml`` file. |
| 168 | +`SecurityBundle`_ stored in the ``app/config/security.yml`` file. |
169 | 169 |
|
170 | 170 | Below is an example of configuration to authenticate the user with an HTTP basic
|
171 | 171 | authentication connected to the database.
|
@@ -326,4 +326,5 @@ from the database.
|
326 | 326 | .. _`UserInterface`: http://api.symfony.com/2.0/Symfony/Component/Security/Core/User/UserInterface.html
|
327 | 327 | .. _`UserProviderInterface`: http://api.symfony.com/2.0/Symfony/Component/Security/Core/User/UserProviderInterface.html
|
328 | 328 | .. _`UsernameNotFoundException`: http://api.symfony.com/2.0/Symfony/Component/Security/Core/Exception/UsernameNotFoundException.html
|
329 |
| -.. _`UnsupportedUserException`: http://api.symfony.com/2.0/Symfony/Component/Security/Core/Exception/UnsupportedUserException.html |
| 329 | +.. _`UnsupportedUserException`: http://api.symfony.com/2.0/Symfony/Component/Security/Core/Exception/UnsupportedUserException.html |
| 330 | +.. _`SecurityBundle`: http://symfony.com/doc/current/reference/configuration/security.html |
0 commit comments