Lines Matching refs:block_size
216 memset(K, 0, ops->block_size); in php_hash_hmac_prep_key()
217 if (key_len > ops->block_size) { in php_hash_hmac_prep_key()
226 php_hash_string_xor_char(K, K, 0x36, ops->block_size); in php_hash_hmac_prep_key()
231 ops->hash_update(context, key, ops->block_size); in php_hash_hmac_round()
271 K = emalloc(ops->block_size); in php_hash_do_hash_hmac()
280 ops->hash_update(context, K, ops->block_size); in php_hash_do_hash_hmac()
290 php_hash_string_xor_char(K, K, 0x6A, ops->block_size); in php_hash_do_hash_hmac()
295 ZEND_SECURE_ZERO(K, ops->block_size); in php_hash_do_hash_hmac()
371 char *K = emalloc(ops->block_size); in PHP_FUNCTION()
374 memset(K, 0, ops->block_size); in PHP_FUNCTION()
376 if (key_len > ops->block_size) { in PHP_FUNCTION()
387 for(i=0; i < ops->block_size; i++) { in PHP_FUNCTION()
390 ops->hash_update(context, (unsigned char *) K, ops->block_size); in PHP_FUNCTION()
521 for(i=0; i < hash->ops->block_size; i++) { in PHP_FUNCTION()
527 hash->ops->hash_update(hash->context, hash->key, hash->ops->block_size); in PHP_FUNCTION()
532 ZEND_SECURE_ZERO(hash->key, hash->ops->block_size); in PHP_FUNCTION()
585 copy_hash->key = ecalloc(1, hash->ops->block_size); in PHP_FUNCTION()
587 memcpy(copy_hash->key, hash->key, hash->ops->block_size); in PHP_FUNCTION()
648 K1 = emalloc(ops->block_size); in PHP_FUNCTION()
649 K2 = emalloc(ops->block_size); in PHP_FUNCTION()
656 php_hash_string_xor_char(K2, K1, 0x6A, ops->block_size); in PHP_FUNCTION()
709 ZEND_SECURE_ZERO(K1, ops->block_size); in PHP_FUNCTION()
710 ZEND_SECURE_ZERO(K2, ops->block_size); in PHP_FUNCTION()
786 ZEND_SECURE_ZERO(hash->key, hash->ops->block_size); in php_hash_dtor()
966 int block_size = ops->digest_size; in PHP_FUNCTION() local
967 int times = bytes / block_size; in PHP_FUNCTION()
968 if (bytes % block_size != 0) times++; in PHP_FUNCTION()
973 key = ecalloc(1, times * block_size); in PHP_FUNCTION()
985 memcpy( &key[i*block_size], digest, block_size); in PHP_FUNCTION()