Gov . Mitt Romney of Massachusetts , who is leaving office , and former Mayor Rudolph W. Giuliani of New York , both Republicans , are also preparing for possible campaigns , although neither has taken any formal legal steps .