Add generate password helper method