WASHINGTON (AP) -- President Barack Obama is confronted with a recent burst of strength by al-Qaida that is chipping away at the remains of Mideast stability, testing his hands-off approach to conflicts in Iraq and Syria at the same time he pushes to keep thousands of U.S. forces in Afghanistan.
Al-Qaida-backed fighters have fought hard against other rebel groups in Syria, in a sideshow to the battle to unseat President Bashar Assad. Across the border in Iraq, they led a surprisingly strong campaign to take two of the cities that U.S. forces suffered heavy losses to protect.
This invigorated front highlights the tension between two of Obama's top foreign policy tenets: to end American involvement in Mideast wars and to eradicate insurgent extremists -- specifically al-Qaida. It also raises questions about the future U.S. role in the region if militants overtake American gains made during more than a decade of war.
In Afghanistan, Obama already has decided to continue the fight against extremists, as long as Afghan President Hamid Karzai signs off on a joint security agreement. Obama seeks to leave as many as 10,000 troops there beyond December, extending what already has become the longest U.S. war. But officials say he would be willing to withdraw completely at the end of this year if the security agreement cannot be finalized.
That would mirror the U.S. exit from Iraq, the other unpopular war Obama inherited. A spike in sectarian violence followed the U.S. withdrawal at the end of 2011, and now followed by the recent, alarming takeover of Ramadi and Fallujah by an al-Qaida affiliate known as the Islamic State of Iraq and the Levant.
Marina Ottaway, a senior scholar at the Woodrow Wilson Center in Washington, said the extremists taking hold in Iraq are a spillover from the conflict in neighboring Syria and have been bolstered by Obama's reluctance to arm the more moderate rebels fighting Assad.
"There is no doubt that the U.S. policy helped create a vacuum in which the only effective forces were the radical forces," Ottaway said Tuesday.
Syria's bloody civil war had not yet begun when the U.S. was making plans to withdraw from Iraq. But White House officials contend that keeping American troops in Iraq would have done little to stop the current violence.
"There was sectarian conflict, violent sectarian conflict, in Iraq when there were 150,000 U.S. troops on the ground there," White House spokesman Jay Carney said. "So the idea that this would not be happening if there were 10,000 troops in Iraq I think bears scrutiny."
Still, Army Chief of Staff Gen. Ray Odierno, a former top commander of U.S. forces in Iraq, said al-Qaida and other insurgents are seeking to take advantage of sectarian tensions across much of the Mideast.
"This is not just about Iraq," Odierno told reporters Tuesday. "It's something that we have to be cognizant of as we look across the Middle East: What's going on in Syria, what's going on in Lebanon, what's going on inside of Iraq."
Iraq now seeks more U.S. weapons, aircraft and intelligence assistance to help battle al-Qaida. Iraqi Ambassador Lukman Faily said in an interview that while Baghdad does not want U.S. troops to return, perhaps Kabul should not reject plans for Americans to stay in Afghanistan.
"The abruptness of the U.S. forces departing from Iraq, versus our own requirement to have sovereignty at any cost, was not something beneficial for all parties," said Faily, Baghdad's top envoy to the U.S. "And what we see now is the aftermath of that. ....There was no clear day-after scenario."
"There is an urgent need for U.S. support," Faily said. "We see this as an issue of U.S. security being in jeopardy as well."
As many as 130,000 people have been killed in Syria, where an insurgency linked to al-Qaida has split rebel groups seeking to oust Assad. Al-Qaida attacks have also spread into Lebanon, and violence spawned by Islamic militants in Sunni-dominated Egypt has risen after last summer's ouster of the Muslim Brotherhood-led government in Cairo.
The tumult has tested Obama's opposition to American military intervention in the region's constant conflict. Critics argue that Obama has lost focus on the Mideast, giving extremists space to strengthen.
While Obama long opposed the Iraq war and has staunchly refused to send U.S. troops to Syria, he appears more comfortable leaving a small military force in Afghanistan. While it's not a war he started, it's one he did build up, flooding the country with 30,000 additional troops in 2010 in his hunt for al-Qaida and the Taliban.
Despite the renewed fighting in Iraq, administration officials argue that keeping a few thousand forces in Afghanistan after the war formally ends later this year would help stabilize the country. The CIA and the Defense Intelligence Agency have warned that a withdrawal will turn the country into a lawless al-Qaida haven.
The U.S. and Afghanistan reached an agreement late last year that would allow for an American contingent to remain, but Karzai so far has refused to sign the security agreement, saying he wants his successor to do so. However, the Obama administration has said it must make plans before then and may be forced to start a full withdrawal if Karzai doesn't change his mind.
Obama administration officials have been quick to cast the rise of al-Qaida militants in Iraq as Baghdad's problem, with Secretary of State John Kerry declaring Sunday that "this is a fight that belongs to the Iraqis." Still, the Pentagon did expedite the delivery of 10 Scan Eagle drones and 100 Hellfire missiles, which are expected to arrive in Iraq this spring.
While much of the violence has spilled over from the neighboring Syrian civil war, Sunni anger has been steadily rising against the Shiite Prime Minister Nouri al-Maliki, who is accused as sidelining Sunnis from power.
Associated Press writers Kimberly Dozier and Lolita C. Baldor contributed to this report.
Follow Julie Pace and Lara Jakes on Twitter: https://twitter.com/jpaceDC and https://twitter.com/larajakesAP