[PHP] Re: mcrypt_create_iv - why so slow?

2013-05-31 Thread Matt Graham
From: Nathan Nobbe > Interesting, using MCRYPT_DEV_URANDOM instead of MCRYPT_DEV_RANDOM > seems practically instantaneous. Still [raises] the question though, > any idea what's holding up the show w/ MCRYPT_DEV_RANDOM? /dev/random is a high quality entropy source and requires more time to generate

[PHP] Re: mcrypt_create_iv - why so slow?

2013-05-30 Thread Nathan Nobbe
Interesting, using MCRYPT_DEV_URANDOM instead of MCRYPT_DEV_RANDOM seems practically instantaneous. Another less elegant solution I've found is to simply str_pad to the length returned by mcrypt_get_iv_size. Still begs the question though, any idea what's holding up the show w/ MCRYPT_DEV_RANDOM?