symfony/symfony — pull request #11797 by dunglas (2014-08-29 09:41:21+00:00)
Title: [Security] Use hash_equals when available for constant-time string comparison

| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a

Use the `hash_equals` function (introduced in PHP 5.6) for timing attack safe string comparison when available.

(https://github.com/symfony/symfony/pull/11795 reopened against the 2.3 branch.)