I have problem that is really easily solved with Guids.
In particular, for a password reset workflow, I would like to send a Guid token to a user\'s email and have
Small update to Simone Carletti answer:
SecureRandom.base64(8).gsub("/","_").gsub(/=+$/,"") => "AEWQyovNFo0"
SecureRandom.base64(8).gsub("/","_").gsub(/=+$/,"")
=> "AEWQyovNFo0"
can be replaced with:
SecureRandom.urlsafe_base64(8)