Pakistan’s spy chief offered to resign Friday amid public outrage over the U.S. operation that killed Osama bin Laden, an incident that humiliated the nation’s army and cast doubt on the capabilities of an intelligence network long believed to be nearly omnipotent.

Lt. Gen. Ahmed Shuja Pasha, in emotional testimony at a private session of Parliament, apologized for what he said was an intelligence lapse and said he would leave his post if Prime Minister Yousaf Raza Gillani deemed him unfit for the job, according to lawmakers. Yet Pasha also spoke in defiant tones about Pakistan’s alliance with the United States, which was severely strained even before the bin Laden killing.

The testimony came hours after suicide bombers killed 80 paramilitary recruits at a training center near the northwestern city of Peshawar, in an attack the Pakistani Taliban claimed as “revenge” for bin Laden’s death. Although police said they were unsure whether that was the motive, the attack seemed likely to deepen anger over the commando raid by the United States, which many Pakistanis view as an unfaithful ally whose military campaign in neighboring Afghanistan has sparked a violent backlash inside Pakistan.

According to one lawmaker, who spoke on the condition of anonymity, Pasha said that ties with the United States had “gone bad” since the secret U.S. raid in the military garrison city of Abbottabad and that Pakistan would be prepared to “resist” any future such operations.

“They want to take action on their own on our soil,” Pasha said of the United States, according to this lawmaker. “We will not allow their boots on our ground.”

Pasha’s statement and offer to resign appeared to be part of an effort to acknowledge denunciations from opposition parties over the intelligence services’ failure to locate bin Laden’s redoubt in Abbottabad.

It was unclear whether Parliament would take action on the resignation offer, or even whether it had the authority. There were no demands during Friday’s session, which stretched into the early hours of Saturday, to accept the offer from Pasha, who has worked closely with the CIA since assuming his post in 2008. Pakistan’s army chief, Gen. Ashfaq Kayani, who was also present at the session, has already declined to accept Pasha’s resignation, lawmakers said.

Once the session ended, Parliament issued a resolution that condemned the U.S. raid in Abbottabad and asked the government to “revisit and review its terms of engagement with the United States.” The resolution expressed confidence in the Pakistani military but also called for an independent investigation into the bin Laden case and the U.S. operation. Earlier this week, Gillani announced that the military would lead an inquiry, a decision that was widely criticized.

The briefing — by Pakistan’s powerful top brass before a civilian body that has nominal influence — was extremely unusual. The army, of which Pasha’s Inter-Services Intelligence directorate is a part, has ruled Pakistan for half of its 64-year existence, and it controls most foreign and security policy matters. As anger over the bin Laden operation has risen, the military has appeared to try to shift blame to the unpopular civilian government.

But the killing of bin Laden within walking distance of the nation’s top military academy has challenged the army’s authority as rarely before. Pakistan was not informed about the helicopter raid, U.S. and Pakistani officials said, nor was it able to stop it once it was underway.

Pakistanis have since deemed the raid a breach of sovereignty and cited it as evidence that the military establishment is unable to protect the nuclear-armed nation or detect dangerous terrorists in its midst. Officials in Washington, meanwhile, have accused Pakistan’s intelligence service of harboring bin Laden to protect its interests in Afghanistan.

In what seemed to be a nod to the public anger, Pasha, who spoke at length while Kayani remained mostly silent, signaled rare deference to Parliament, acknowledging that politicians had criticized the security services for “ignoring” elected officials, according to one lawmaker, Riaz Fatiana.

Yet Pasha also vigorously defended the ISI, saying — as military officials have done repeatedly in the past week — that it has captured or killed hundreds of al-Qaeda operatives and other high-value terrorists. He and other military officials who spoke said they would review Pakistan’s military alliance with the United States if directed by Parliament, Fatiana said.

But in a sign that Pakistan and the United States continue to cooperate despite the tensions, the Pentagon confirmed Friday that Pakistan has allowed U.S. investigators to question three of bin Laden’s wives, who were living with him in Abbottabad when he was killed.

They were taken into custody by Pakistani authorities after U.S. Navy SEALs left bin Laden’s compound with his body. Marine Col. Dave Lapan, a Defense Department spokesman, said that “we have had access to the widows.” But he declined to give details, such as where, when and under what circumstances the women were questioned. Pakistani intelligence officials have said one of the wives is Yemeni and two are Saudi.

Doubt over attack motive

Most of the victims of Friday’s bombings were newly minted cadets who were boarding buses for a 10-day leave.

The Pakistani Taliban, a homegrown offshoot of the Afghan militant group, asserted responsibility and said the bombings were meant as revenge for bin Laden’s death. Some local police officials cast doubt on that, saying the militants might have been from the neighboring Mohmand region, a section of Pakistan’s semiautonomous tribal area where the army recently re-launched an operation to flush out Islamist militants.

Pakistan’s border with Afghanistan is the hub of al-Qaeda, the Taliban and a host of other affiliated militant organizations. The United States has provided billions of dollars to fund Pakistan’s counterinsurgency fight in the area. and U.S. officials are pressuring Pakistan to wage an offensive in the North Waziristan area, which is the base for several insurgent groups that target NATO forces in Afghanistan.

North Waziristan has been the target of an escalated CIA drone campaign, which is another source of tension between the United States and Pakistan. One such drone strike, the fourth since bin Laden’s death, killed four people in North Waziristan on Friday, authorities said.

Hussain is a special correspondent. Special correspondent Haq Nawaz Khan in Shabqadar, Pakistan, and staff writer Craig Whitlock in Washington contributed to this report.