Skip to content

Commit f42bd71

Browse files
committed
Remove deprecated StringUtils from WSSE custom auth provider
1 parent ecc2ca0 commit f42bd71

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

cookbook/security/custom_authentication_provider.rst

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,6 @@ the ``PasswordDigest`` header value matches with the user's password.
214214
use Symfony\Component\Security\Core\Exception\NonceExpiredException;
215215
use Symfony\Component\Security\Core\Authentication\Token\TokenInterface;
216216
use AppBundle\Security\Authentication\Token\WsseUserToken;
217-
use Symfony\Component\Security\Core\Util\StringUtils;
218217
219218
class WsseProvider implements AuthenticationProviderInterface
220219
{
@@ -273,7 +272,7 @@ the ``PasswordDigest`` header value matches with the user's password.
273272
// Validate Secret
274273
$expected = base64_encode(sha1(base64_decode($nonce).$created.$secret, true));
275274
276-
return StringUtils::equals($expected, $digest);
275+
return hash_equals($expected, $digest);
277276
}
278277
279278
public function supports(TokenInterface $token)

0 commit comments

Comments
 (0)