generate secret key randomly