U.S. officials are becoming increasingly resigned to the possibility of a protracted stalemate in Libya, with rebels retaining control of the eastern half of the divided country but lacking the muscle to drive Moammar Gaddafi from power.

Such a deadlock — perhaps backed by a formal cease-fire agreement — could help ensure the safety of Libyan civilians caught in the crossfire between the warring sides. But it could also dramatically expand the financial and military commitments by the United States and allied countries that have intervened in the six-week-old conflict, according to U.S. officials familiar with planning for the Libyan operation.

New evidence of a possible impasse emerged Friday as an opposition spokesman called publicly for a cease-fire that would halt the fighting and essentially freeze the battle lines. The Libyan government rejected the proposal, saying it would not “withdraw from our own cities.”

At the same time, British officials privately disclosed a recent visit to London by a senior aide to one of Gaddafi’s sons, prompting new speculation that those close to the Libyan leader were exploring ways to end the fighting.

Gaddafi loyalists continued to pound rebel fighters in the key oil hub of Brega, a town that had been claimed by anti-government forces less than a week ago. Yet, despite repeated setbacks in recent days, intelligence assessments suggest that the rebels, with continuing NATO air support, are capable now of maintaining control of strongholds such as Benghazi as well as key oil fields in eastern Libya, according to two U.S. officials privy to classified reports from the region who agreed to discuss them only on the condition of anonymity.

U.S. analysts have concluded that Gaddafi will likely not step aside voluntarily, despite recent defections by top aides. Nor is he likely to be driven anytime soon from his Tripoli base, where he has surrounded himself with highly paid fighters and tribal kinsmen who remain fiercely loyal, the officials said.

One likened the current conflict to an evenly matched football game, with two sides skirmishing over a few yards in midfield.

“Neither side seems capable of moving the ball down the field,” said the U.S. official. “It is also true that neither side has endless resources.”

A stalemate could mean an open-ended mission for the coalition of NATO and Arab countries now enforcing the no-fly zone over Libya, increasing both the financial and political costs for the participants. But analysts are increasingly confident that Gaddafi can be largely contained within a divided Libya, unable to significantly threaten his neighbors and gradually weakening over time.

“He remains a danger . . . but over time he could be squeezed,” said a second U.S. official familiar with intelligence assessments. While it is possible that Gaddafi could be assassinated or overthrown, he maintains an elaborate, multilayered personal security system that has protected him for decades. “By all accounts he is very paranoid, and he will fend for his own survival,” the official said.

Defense Secretary Robert M. Gates did not mention such an outcome when he was asked in congressional testimony Thursday about likely results.

One scenario, Gates said, was “that somebody from his military takes him out and then cuts a deal with the opposition.” In another case, Gaddafi’s loyalist tribes “abandon him and then cut their own deals with each other.”

“Another alternative would be clearly our preferred option, which would be that they — these opposition forces and the tribes — come together and begin to create something that resembles a more democratic state that protects the rights of its people,” he said.

At a separate hearing last week, Gen. Carter F. Ham, head of U.S. Africa Command, acknowledged the possibility of a deadlock in which Gaddafi would continue to control part of the country.

“I do see a situation where that could be the case,” he said. “I could see accomplishing the military mission, which has been assigned to me, and the current leader would remain the current leader.”

U.S. officials and independent analysts say that Gaddafi has been badly weakened by defections, airstrikes and a freeze on his foreign-held assets, and that he has few allies outside of Latin America.

Anthony Cordesman, a defense and security analyst for the Center for Strategic and International Studies, said Gaddafi’s internal support would likely “erode from the margins,” as tribal leaders and military commanders peel off despite his ability to pay them. But the prospects are nearly as grim for his opponents, a rebel force with “no discipline, no communications and no intelligence, and at best an improvised logistics and supply chain.”

“You can’t fix those things quickly or easily,” he said.

With their proposal for a cease-fire, Libyan rebels appeared to acknowledge their inability to prevail militarily. A spokesman for the opposition offered to halt fighting if Gaddafi would withdraw his troops from Libyan cities and allow people to speak freely.

“We are seeking immediate withdrawal of Gaddafi forces around and inside cities to give Libyan people the freedom to choose,” said Mustafa Abdel Jalil, president of the opposition’s provisional council.

“Our main aim is to remove the siege from the cities,” he said at a news conference with a United Nations envoy.

Government spokesman Moussa Ibrahim dismissed the offer. “If this is not mad, then I don’t know what is. We will not leave our cities,” Ibrahim said.

Talk of a cease-fire comes at the end of a week in which rebel forces briefly regained two oil ports and then were repelled back to Ajdabiya, 99 miles from the rebel stronghold of Benghazi.

In Tripoli, meanwhile, heavy gunfire erupted before dawn Friday as tensions rose in the capital following rumors that other government officials were preparing to join Foreign Minister Musa Kusa in defecting from Gaddafi’s government.

Sustained bursts of automatic fire were heard coming from the direction of Gaddafi’s Bab al-Aziziya compound about 2 a.m. and again shortly before dawn. Ambulances and police cars were seen speeding through the deserted streets, but there was no immediate explanation for the unusual overnight activity.

Witnesses told Reuters that they had seen “pools of blood” outside the compound that had been cleaned away by morning. One said sharpshooters had been positioned on high buildings around the capital, perhaps to preempt any possible demonstrations after Friday prayers, which had served as a rallying point for opposition protests before they were stamped out. Journalists who attempted to leave their hotel unaccompanied by government minders were turned back by armed men.

Kusa was the most senior Gaddafi minister to abandon the regime, and his defection in London on Wednesday prompted appeals by U.S. and British officials for other top figures to follow him into exile. But there were no new reports Friday of defections.

A senior aide to Gaddafi’s powerful son Saif al-Islam has been in London recently talking to government officials, a British official said Friday, speaking on the condition of anonymity. The official said Mohammed Ismail “has family in the U.K., I believe his children are in school here, and while he was visiting family we took the opportunity to talk to him. We gave him strong messages about the Gaddafi regime and told him it was time for Gaddafi to go, and encouraged those around Gaddafi to leave.”

British media reports have speculated that Ismail was exploring exit strategies with British officials for one or more members of the Gaddafi family.

A spokesman at the British Foreign Office declined to comment on Ismail’s visit but said talks with Kusa are “ongoing.”

Sly reported from Tripoli. Special correspondent Karla Adam in London and staff writer Craig Whitlock contributed to this report.