Pakistani commandos freed 22 soldiers and civilians being held hostage by militants inside army headquarters in the garrison city of Rawalpindi, killing four of the militants in a dawn raid Sunday, the military said.
Three of the hostages were reported killed in the rescue, which took place about 18 hours after a handful of armed Taliban militants took the hostages after attacking the main gate of the headquarters on Saturday, killing six soldiers including a brigadier general.
Army spokesman Maj. Gen. Athar Abbas said "mopping operations" were continuing early Sunday.
Gen. Abbas said most of the hostages had been kept in a single room guarded by a militant wearing a suicide vest. He said commandos shot the guard before he could detonate his explosives. He said the 22 hostages who were freed included soldiers and civilians. Three captives were killed, along with four militants, he said.
The army on Saturday had said between 10 and 15 soldiers were being held hostage.
Pakistani news media reported that the Taliban had claimed responsibility for Saturday's attack.
Officials and analysts were stunned by the serious breach of security in one of the most heavily guarded areas of Pakistan, a nuclear-armed nation.
Gen. Abbas told Pakistan's Geo TV that the gunmen had eluded security forces and slipped into the compound.
The militants, heavily armed and disguised in military uniforms, struck at the heart of Pakistan's military establishment.
"This attack underscores the audacity of the Taliban," Bruce Riedel, a senior fellow at the Brooking Institution's Saban Center for Middle East Policy, told The Washington Times. "Attacking the Pakistani Pentagon shows the jihadists can strike anywhere."
The attack came as Pakistan's military readies for an offensive against militants holed up in the mountainous South Waziristan province in the country's northwest.
The attack and hostage-taking played out a stone's throw away from the Pakistani capital, Islamabad, highlighting the deadly potency of the Pakistani Taliban at a time when reports suggest that one of the strategies the Obama administration is contemplating is a softer approach toward the Taliban in Afghanistan.
Lisa Curtis, a South Asia analyst at the Heritage Foundation, said recent statements from the White House "making distinctions between the Taliban and al Qaeda and implying that the Taliban is somehow less inimical to U.S. interests are incongruous with developments on the ground."
Mr. Riedel dismissed the rationale behind that strategy - that al Qaeda, not the Taliban, is the real enemy - as a "fairy tale." He said the attack in Rawalpindi showed the extent of the Taliban's reach.
Mr. Riedel, who oversaw a review of Mr. Obama's Afghanistan-Pakistan strategy, said the bar for determining whether the Taliban is willing to enter into serious negotiations with the United States should be whether it is willing to hand over al Qaeda leader Osama bin Laden.
A shuttle van driver who witnessed Saturday's attack told the Associated Press, "There was fierce firing, and then there was a blast."
"Soldiers were running here and there," Khan Bahadur said. "The firing continued for about a half-hour. There was smoke everywhere. Then there was a break, and then firing again."
The assailants drove to the army headquarters in a white van with military plates.
A police intelligence report in July obtained by the AP on Saturday warned that members of the Taliban, along with Jaish-e-Mohammed, a militant group based in the country's Punjab province, were planning to attack army headquarters disguised as soldiers.
The attack in Rawalpindi comes on the heels of a warning from Pakistani Taliban leader Hakimullah Mehsud that his fighters will avenge the death of their former leader, Baitullah Mehsud, in a U.S. drone attack in August, and resist the army's operation in Waziristan.
The Pakistani government vowed to press ahead with its offensive in South Waziristan.
"I want to give a message to the Taliban that what we did with you in Swat, we will do the same to you there [in Waziristan], too," said Interior Minister Rehman Malik, referring to the military's operation that drove the Taliban out of the picturesque Swat Valley, about 100 miles northwest of Islamabad.
"We are going to come heavy on you," Mr. Malik said.
Officials said Saturday that they had raided a house in the capital where the attackers were thought to have stayed. They found military uniforms and bomb-making equipment.
Saturday's assault was the latest in a string of attacks by the Taliban. A suicide bomber blew himself up outside the Indian Embassy in Kabul, Afghanistan, last week, and a bombing across the border in Peshawar, Pakistan, killed at least 49.
Earlier this month, a Taliban suicide bomber struck the U.N. World Food Program office in Islamabad. That attack killed five employees. The bomber who attacked the U.N. office was also wearing a security forces uniform and was granted entry to the compound after asking to use the bathroom.
Indian and Afghan officials have accused Pakistan's Inter-Services Intelligence agency of playing a role in the attack on the Indian Embassy.
But Sumit Ganguly, director of research at the Center on American and Global Security at Indiana University in Bloomington, said the attack in Rawalpindi showed some factions of the Taliban "may well be out of the hands of their Pakistani mentors."
"Furthermore, some of these factions may well be unhappy with the willingness of [Pakistani President Asif Ali] Zardari's government to work with the U.S.," Mr. Ganguly told The Times.
Pakistan's military and opposition leaders have chastised the Zardari government over U.S. legislation that links military aid to Pakistan to cooperation from Islamabad in the war against the Taliban, al Qaeda and other terrorist groups.
In an interview with editors and reporters at The Times on Wednesday, Pakistani Foreign Minister Makhdoom Shah Mahmood Qureshi said "better language could be used" in the legislation.
Ashish Kumar Sen is a reporter covering foreign policy and international developments for The Washington Times.
Prior to joining The Times, Mr. Sen worked for publications in Asia and the Middle East. His work has appeared in a number of publications and online news sites including the British Broadcasting Corp., Asia Times Online and Outlook magazine.
By John Solomon
How the government's punishing of the exposure of official wrongdoing can linger for years
Independent voices from the TWT Communities
A collection of reader guest articles, thoughts and opinions by Communities writers and breaking news and information.
Great discoveries in the world of restaurants and chefs fulfill the quest for delicious food and cooking.
Paul Rondeau dissects the propaganda, media tricks, and other shenanigans targeting our families, faith, and freedom…and even life itself
Benghazi: The anatomy of a scandal
Vietnam Memorial adds four names
Cinco de Mayo on the Mall
NRA kicks off annual convention