DRY up random key generation

Remove key generation responsibility from ActiveRecord classes
Use uuid for key generation