Ivo H. Daalder, a foreign policy scholar at the nonpartisan Brookings Institution, saw a clear motivation in Obama and Clinton resisting the calls from within their party for an immediate troop withdrawal: Whoever wins the Democratic nomination will need to appeal to centrist, independent voters as well as antiwar Democrats.
"The lesson for the past 30 years for Democrats has been that if you don't prove you're tough, you don't make it past the first step," said Daalder, who supports Obama.
"They are thinking about general elections, not primary elections," said John Isaacs, an antiwar activist who is head of the Council for a Livable World. "They recognize they have to appeal not only to the primary audience, but also to the general electorate.... It's a tough balancing act."
Among the leading Republican candidates, the Iraq debate has been more muted -- a matter of nuances amid strong statements of support for the war effort.
McCain, who long has criticized the Bush administration for not sending enough troops to Iraq, was a vocal supporter of the president's decision earlier this year to launch the surge of combat troops; McCain was also a scathing critic of Democrats who called for withdrawal.
"We have a new general, a new strategy," McCain said at a Republican debate at the Ronald Reagan Presidential Library in Simi Valley this month. "That strategy can succeed."
Army Gen. David H. Petraeus, Bush's commander in Iraq, is due to deliver a progress report on the troop surge's effectiveness in early September.
But McCain has opposed calls from moderate Republicans in Congress for a reassessment at that time. "We have to show some progress, obviously," he said in Iowa last week. "But for us to say the month of September, the month of October, the month of January or any other month is going to be the defining moment is something that I simply don't agree with."
Romney has begun sounding a slightly different theme: that the time to evaluate the effects of the surge may come soon. "I think we're going to know whether this is working in a matter of months, not years," he has said several times.
But when a Romney spokesman, Kevin Madden, was asked how many months Romney had in mind, he replied: "That will depend on input from the military commanders.... It could be 15 months."
Giuliani, who has not given a major foreign policy speech, has focused instead on renewing the nation's determination to fight terrorism around the world.
"America is not about defeat; America is about victory," he said in a Citadel graduation speech May 5. "The only good defense is a strong offense. Those who counsel defeat, those who advocate that we share with our enemy a timetable of our troop withdrawal, don't lack patriotism or love of this country. What they lack is a clear vision of what we're facing to keep us safe."
The GOP presidential candidates' dogged support of the war puts them out of step with some leading congressional Republicans, who have warned the White House that their ranks will break unless the surge clearly shows positive results by September.
"This comes down to their individual races," said Kirk Blalock, a former aide to White House political strategist Karl Rove. "They're worried about what happened in the last election," when Democrats took control of the Senate and House, he said.
Republican senators will be running for reelection next year in Minnesota, Maine and New Hampshire, all states where the war is deeply unpopular, Blalock said. "Presidential candidates are running to lead the country as a whole in the war on terror," he said. "Congressional candidates are more prone to be affected by the mood swings of their constituents."
(BEGIN TEXT OF INFOBOX)
What they're saying about Iraq
Rudolph W. Giuliani
Opposes a timetable for withdrawal of U.S. troops. Says failure of the U.S. effort would lead to a broader regional conflict.
Quote: "Never, ever wave the white flag of defeat in front of those who want to come here and kill you and take away your way of life. Never."
The Arizona senator voted in 2002 to authorize the war. Backs President Bush's troop "surge" and advocates making it larger. Has strongly rejected timetables or fixed benchmarks for success.
Quote: "We must win in Iraq. If we withdraw, there will be chaos, there will be genocide, and [terrorists] will follow us home."
Supports the troop buildup and opposes Democratic plans for a withdrawal timetable. But also says the "surge" may not work and that the war has been mismanaged. Expresses understanding for opponents of the war.
Quote: "We were under-planned, understaffed, under-managed, and there's a lot of anger [among Americans] about how it's not gone like they thought it would. That being said, pulling out right now has some additional risks for our country that we have to think about."
Hillary R. Clinton