From 0f67a1d6ccb3f51701461b07656743fa3959c30a Mon Sep 17 00:00:00 2001 From: Alexander Schwenn Date: Sat, 3 Jan 2015 22:28:35 +0100 Subject: [PATCH] [Book][Security] Add isPasswordValid doc as in 2.6 --- book/security.rst | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/book/security.rst b/book/security.rst index e9dc4df6826..713d291b8ce 100644 --- a/book/security.rst +++ b/book/security.rst @@ -1117,6 +1117,10 @@ In order for this to work, just make sure that you have the encoder for your user class (e.g. ``AppBundle\Entity\User``) configured under the ``encoders`` key in ``app/config/security.yml``. +The ``$encoder`` object also has an ``isPasswordValid`` method, which takes +the ``User`` object as the first argument and the plain password to check +as the second argument. + .. caution:: When you allow a user to submit a plaintext password (e.g. registration