dynamically generate a secret key.