Skip to content
This repository has been archived by the owner on Jan 8, 2020. It is now read-only.

Use hash_equals for constant-time string comparison #6621

Closed
wants to merge 2 commits into from

Conversation

dunglas
Copy link

@dunglas dunglas commented Sep 2, 2014

Use the hash_equals function (introduced in PHP 5.6) for timing attack safe string comparison when available.
Add in the DocBlock that length will leak (see php/php-src#792).

@Ocramius
Copy link
Member

This was merged into develop at 2893ec8, thanks!

@Ocramius Ocramius closed this Nov 22, 2014
gianarb pushed a commit to zendframework/zend-crypt that referenced this pull request May 15, 2015
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants