unify random password generation