File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -201,6 +201,7 @@ the ``PasswordDigest`` header value matches with the user's password.
201
201
use Symfony\Component\Security\Core\Exception\AuthenticationException;
202
202
use Symfony\Component\Security\Core\Exception\NonceExpiredException;
203
203
use Symfony\Component\Security\Core\Authentication\Token\TokenInterface;
204
+ use Symfony\Component\Security\Core\Util\StringUtils;
204
205
use Acme\DemoBundle\Security\Authentication\Token\WsseUserToken;
205
206
206
207
class WsseProvider implements AuthenticationProviderInterface
@@ -260,7 +261,7 @@ the ``PasswordDigest`` header value matches with the user's password.
260
261
// Validate Secret
261
262
$expected = base64_encode(sha1(base64_decode($nonce).$created.$secret, true));
262
263
263
- return $digest === $expected ;
264
+ return StringUtils::equals($expected, $digest) ;
264
265
}
265
266
266
267
public function supports(TokenInterface $token)
You can’t perform that action at this time.
0 commit comments