I would like to deploy an application to heroku which needs to be able to generate cryptographically secure random numbers. What entropy sources can I use?
Your Heroku dyno is basically an Ubuntu Server VM, so you should have access to /dev/random
and /dev/urandom
like you would on any other Linux-based OS.
If you're using Ruby/Rails, you should probably be using SecureRandom
(or ActiveSupport::SecureRandom
for older versions of Ruby and Rails) for this.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With