From 3ace4d6d36292eb9b43fd3fd3c0eab638ceafcae Mon Sep 17 00:00:00 2001 From: Christian Flothmann Date: Thu, 13 Mar 2014 22:33:53 +0100 Subject: [PATCH] add missing code block directive --- cookbook/security/api_key_authentication.rst | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/cookbook/security/api_key_authentication.rst b/cookbook/security/api_key_authentication.rst index e27ef087c90..c027012052b 100644 --- a/cookbook/security/api_key_authentication.rst +++ b/cookbook/security/api_key_authentication.rst @@ -214,11 +214,13 @@ Handling Authentication Failure ------------------------------- In order for your ``ApiKeyAuthentication`` to correctly display a 403 -http status when either bad credentials or authentication fails you will -need to implement the :class:`Symfony\Component\Security\Http\Authentication\AuthenticationFailureHandlerInterface` on your -Authenticator. This will provide a method ``onAuthenticationFailure`` which +http status when either bad credentials or authentication fails you will +need to implement the :class:`Symfony\Component\Security\Http\Authentication\AuthenticationFailureHandlerInterface` on your +Authenticator. This will provide a method ``onAuthenticationFailure`` which you can use to create an error ``Response``. +.. code-block:: php + // src/Acme/HelloBundle/Security/ApiKeyAuthenticator.php namespace Acme\HelloBundle\Security;