Skip to content

Commit 3475c0c

Browse files
committed
Merge branch 'PHP-7.0' into PHP-7.1
* PHP-7.0: Securely zero the hash context key
2 parents de64ade + bf0f532 commit 3475c0c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ext/hash/hash.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -894,7 +894,7 @@ static void php_hash_dtor(zend_resource *rsrc) /* {{{ */
894894
}
895895

896896
if (hash->key) {
897-
memset(hash->key, 0, hash->ops->block_size);
897+
ZEND_SECURE_ZERO(hash->key, hash->ops->block_size);
898898
efree(hash->key);
899899
}
900900
efree(hash);

0 commit comments

Comments
 (0)