Lines Matching refs:buffer
39 pool->buffer = OPENSSL_secure_zalloc(pool->alloc_len); in ossl_rand_pool_new()
41 pool->buffer = OPENSSL_zalloc(pool->alloc_len); in ossl_rand_pool_new()
43 if (pool->buffer == NULL) in ossl_rand_pool_new()
61 RAND_POOL *ossl_rand_pool_attach(const unsigned char *buffer, size_t len, in ossl_rand_pool_attach() argument
74 pool->buffer = (unsigned char *) buffer; in ossl_rand_pool_attach()
101 OPENSSL_secure_clear_free(pool->buffer, pool->alloc_len); in ossl_rand_pool_free()
103 OPENSSL_clear_free(pool->buffer, pool->alloc_len); in ossl_rand_pool_free()
114 return pool->buffer; in ossl_rand_pool_buffer()
141 unsigned char *ret = pool->buffer; in ossl_rand_pool_detach()
142 pool->buffer = NULL; in ossl_rand_pool_detach()
151 void ossl_rand_pool_reattach(RAND_POOL *pool, unsigned char *buffer) in ossl_rand_pool_reattach() argument
153 pool->buffer = buffer; in ossl_rand_pool_reattach()
154 OPENSSL_cleanse(pool->buffer, pool->len); in ossl_rand_pool_reattach()
221 memcpy(p, pool->buffer, pool->len); in rand_pool_grow()
223 OPENSSL_secure_clear_free(pool->buffer, pool->alloc_len); in rand_pool_grow()
225 OPENSSL_clear_free(pool->buffer, pool->alloc_len); in rand_pool_grow()
226 pool->buffer = p; in rand_pool_grow()
302 const unsigned char *buffer, size_t len, size_t entropy) in ossl_rand_pool_add() argument
309 if (pool->buffer == NULL) { in ossl_rand_pool_add()
323 if (pool->alloc_len > pool->len && pool->buffer + pool->len == buffer) { in ossl_rand_pool_add()
336 memcpy(pool->buffer + pool->len, buffer, len); in ossl_rand_pool_add()
366 if (pool->buffer == NULL) { in ossl_rand_pool_add_begin()
383 return pool->buffer + pool->len; in ossl_rand_pool_add_begin()