ISLAMABAD (Reuters) -- A suspected suicide bomber has killed 41 people in an attack on the Pakistani military as the Taliban claimed responsibility for a weekend raid on the army's headquarters.
Militant attacks have intensified over the past week as the army prepares to launch a ground offensive on the Al-Qaeda-linked fighters' South Waziristan stronghold.
Pakistani Taliban militants linked to Al-Qaeda have launched numerous attacks on government and foreign targets over the past couple of years killing hundreds of people.
The target of the attack in Shangla district, near the Swat Valley, was a military convoy, police said.
"It appears to be a suicide attack. The bomber hit one of three military vehicles that were passing through the busiest market in the district," top Shangla police official, Khan Bahadur Khan, said by telephone.
Provincial Information Minister Mian Iftikhar Hussain said 41 people had been killed, including 35 civilians and six soldiers, and 45 people were wounded.
Members of the Pakistani Taliban and Al-Qaeda were suspected to have been behind the October 10 attack on army headquarters in Rawalpindi, near Islamabad.
Commandos stormed an office building near the headquarters and rescued 39 people taken hostage by gunmen after an attack at a main gate of the headquarters.
Nine militants and three hostages were killed in the violence in Rawalpindi while the number of soldiers killed rose to 11, with the death of three wounded men, a military official said.
Pakistani Taliban spokesman Azam Tariq claimed responsibility and threatened more attacks.
"It was carried out by our Punjab unit," Tariq said by telephone, referring to Punjab province where Islamist militants linked to both Al-Qaeda and the Taliban operate.
"We will take revenge for our martyrs and will carry out more attacks, whether it's the GHQ or something bigger," he said, referring to the army's General Headquarters.
Pakistani aircraft attacked Taliban militants in their South Waziristan stronghold on October 11, killing about 16 militants, a Pakistani intelligence official in the region said.
The military has been conducting air and artillery strikes in South Waziristan for months, while moving troops, blockading the region and trying to split off militant factions.
But a ground offensive, in what could be the army's toughest test since the militants turned on the state, has yet to begin.
Interior Minister Rehman Malik told Reuters in an interview in Singapore the offensive was "imminent."
"There is no mercy for them because our determination and resolve is to flush them out," Malik said. "They have no room in Pakistan, I promise you."
Malik said the offensive against the militants in South Waziristan was no longer a matter of choice.
"It is not an issue of commitment, it is becoming a compulsion because there was an appeal from the local tribes that we should do the operation," he said.
About 28,000 troops have been put in place to take on an estimated 10,000 hard-core Taliban, army officials said earlier.