WASHINGTON (AP) -- For two years, the Obama administration has had a relationship of convenience with Yemen: The U.S. kept the Yemeni government armed and flush with cash. In return, Yemen's leaders helped fight al-Qaida or, as often, looked the other way while the U.S. did.
That relationship is about to get a lot less convenient.
Of all the uprisings and protests that have swept the Middle East this year, none is more likely than Yemen to have immediate damaging effects on U.S. counterterrorism efforts. Yemen is home to al-Qaida's most active franchise, and as President Ali Abdullah Saleh's government crumbles, so does Washington's influence there.
On Tuesday, Saleh pledged to step down by year's end. His 32-year hold on power has weakened during street protests over the past month.
Several foreign diplomats have turned against him. On Monday, three senior army commanders joined a protest movement calling for his ouster. But Saleh vowed not to hand power to them and branded their defections as an attempted coup.
Current and former U.S. government officials and analysts speculated on Saleh's fall.
"In the counterterrorism area, it will be a great loss," said Wayne White, a former senior State Department intelligence analyst.
Whoever replaces Saleh will inherit a country on the brink of becoming a failed state. There is a secessionist movement in the south. Pirates roam its waters. A rebellion in the north has been a proxy fight between Iran and Saudi Arabia. Half of Yemen's citizens are illiterate. A third are unemployed. Drinking water is scarce, yet the population is growing at one of the fastest clips in the world, far outpacing the government's ability to provide even the most basic services. Half the country lacks toilets.
With all that, the challenge for the U.S. will be to persuade Yemen's next leader to continue an unpopular campaign against al-Qaida. Sheik Hamid al-Ahmar, a leading member of the opposition who has been mentioned as a possible president, has dismissed al-Qaida in Yemen as a creation of Saleh's government. The Obama administration, however, considers the group to be the most serious terrorist threat to the U.S.
The group, known as al-Qaida in the Arabian Peninsula, includes about 300 people sheltered by tribal allies in a rugged, hard-to-travel country twice as big as Wyoming. The group was behind the nearly successful bombings of U.S. cargo jets last fall and a passenger airliner on Christmas 2009. The attacks grabbed the attention of Washington, which previously had regarded the terrorist group as a threat only in the Middle East.
The Obama administration responded by stepping up airstrikes in Yemen and encouraging Saleh to carry out raids based on U.S. intelligence. Aid to Yemen more than doubled. Green Berets and Navy SEALs trained Yemeni counterterrorism forces, and U.S. security teams arrived with airport screening equipment.
Last year, the CIA established a new department in the Counterterrorism Center to deal with al-Qaida in Yemen and al-Shabab in Somalia. The CIA station in Yemen's capital, Sana'a, meanwhile, has grown in recent years from an office of a few dozen people to a bustling station several times larger.
Despite the recent push, the U.S. still has little clarity about what the Yemeni government would look like without Saleh. The Obama administration has not speculated publicly about it, but officials believe the two countries share a counterterrorism interest that goes beyond any one person.
For years, the U.S. knew it could influence Yemen by influencing Saleh and those close to him. Because the government there is notoriously secretive, and influence is traded among tribal and tribal leaders, the U.S. has struggled to understand the world behind Saleh's leadership.
"I don't think we know who runs Yemen and what they think," said Christopher Boucek, a scholar at the Carnegie Endowment for International Peace who briefs government officials and recently testified before Congress about Yemen. "I don't think we know very much about who they are, how they're connected to each other, what their family relationships are."
Earlier this month, the Congressional Research Service produced a 48-page analysis for lawmakers on the situation in Yemen. The question of who might replace Saleh was among the first topics. But the research paper devoted just two paragraphs to it, mostly speculation.
"Currently, there is no real consensus alternative to President Saleh," researchers wrote. "The security forces are led by members of his extended family and uprooting all of them may lead to civil war and the dissolution of the country."
Further complicating U.S. efforts to build a new partnership in Yemen is the fact that one of the driving forces behind the protests is the country's fundamentalist Islamic opposition party, known as Islah. The party's spiritual leader, Sheik Abdel-Majid al-Zindani, is on a U.S. list of terrorists and has been described as a loyalist of Osama bin Laden. Though experts caution that Islah today is held together by shared opposition to Saleh, the group's ties to al-Zindani would make it harder for Washington to justify spending more money to arm or stabilize an Islah-led Yemen.
In its statements about Yemen, the Obama administration has been careful not to put too much pressure on its fragile ally. After 40 people died in a government crackdown on protests last week, the White House called for calm. But it has not publicly backed Saleh or the protest movement.
"Our message to everybody involved is that this should be channeled into a political dialogue in pursuit of a political solution and a government that is responsive to Yemenis," deputy national security adviser Ben Rhodes said Monday.
On the question of who succeeds Saleh, perhaps the worst possible answer for Washington is no one. A civil war, a series of unsuccessful leaders or a failed state would provide al-Qaida with even more mobility and sanctuary. The worse things get for Yemen, the harder it would be for the government to turn any attention toward fighting terrorism.
"You're talking about three insurgencies, no water, no oil, a failing economy, a food crisis," Boucek said. "How much can this country take?"