KABUL/PESHAWAR, Pakistan (Reuters) - Afghanistan’s main spy agency said on Wednesday it had killed the Taliban commander behind a deadly attack on one of its bases this week, and vowed to hunt down and kill all the rest of those involved.

Afghan men stand in front of a collapsed building of a military base after a car bomb attack in Maidan Wardak, Afghanistan, January 21, 2019. REUTERS/Stringer

The National Directorate of Security (NDS) said the Taliban commander, identified only as Noman, was killed in an air strike on Tuesday night.

The agency said Noman was the mastermind of a Monday attack on an NDS base in Maidan Wardak province, west of Kabul, in which the NDS said 36 people were killed and 58 wounded. Other officials said the casualty toll was higher.

“Noman, along with seven others, was targeted after being identified by the NDS forces,” the security agency said in a statement.

“NDS will follow the terrorist group and kill them all.”

The Taliban issued a statement, denying that the commander had been killed.

The insurgent attack in Maidan Wardak was the latest to inflict heavy casualties on government forces and underlined the pressure they face as increasingly confident fighters step up violence, even as diplomatic efforts to end the conflict are underway.

In Monday’s attack, the Taliban detonated a captured military Humvee packed with explosives. Some government officials said the casualty toll was higher than the one given by the NDS.

A senior defense source had told Reuters 126 members of the Afghan security forces were killed. Two senior security officials in the capital, Kabul, said at least 72 men being trained by the NDS were killed with 38 severely wounded.

The Taliban said their attack killed 190 people.

It was not immediately clear if Tuesday’s air strike was supported by U.S. forces.

Afghan forces backed by U.S. air strikes have been targeting Taliban commanders, but questions have been raised over the future of U.S. involvement by reports that President Donald Trump wants to bring home almost half of the 14,000 U.S. troops.

‘HEATED ARGUMENTS’

Officials in Maidan Wardak gave conflicting accounts of the violence that followed Monday’s Taliban attack.

Mohebulla Sharifzai, spokesman for the provincial governor said the NDS had killed six gunmen in an air strike in the provincial capital, but he was not sure if Taliban commander Noman was among them.

A second provincial official said the NDS, with support from foreign forces, conducted two raids.

“An air strike conducted by foreign forces killed three men and a boy, they were not gunmen but hunters,” said Akhtar Mohammad Taheri, head of Maidan Wardak’s provincial council.

Taheri told Reuters in the second raid, NDS forces hunting militants killed five civilians from the same family. An NDS spokesman was not available for comment and did not respond to requests for comment.

The surging violence came as Taliban leaders met U.S. officials in Qatar for talks to try to agree on a way to end the 17-year war.

Officials from the two sides have met at least four times in recent months but the militants have refused to talk to the U.S.-backed Kabul government.

The Taliban say they are fighting to oust foreign troops, topple the government and restore strict Islamic law.

The United States and its allies say they want to stop Afghanistan from becoming a haven for international militants plotting attacks in the West.

Taliban officials privy to the talks, which entered an unscheduled third day on Wednesday, said U.S. negotiators, led by special envoy for peace Zalmay Khalilzad, were concerned about deteriorating security and feared that a U.S. withdrawal could lead to “terrorist groups” taking control in Afghanistan.

The two sides exchanged “heated arguments and counter-arguments”, said a senior Taliban official who declined to be identified.

“Our delegation made it clear that they would never let Afghanistan to be used against any other country,” the official said.