An attack on a Pakistani military checkpost by some 200 pro-Taliban militants triggered intense fighting that killed 25 insurgents and two paramilitary soldiers near the Afghan border, security officials said Thursday.

The fighting broke out Wednesday in Loi Sam village in the Bajur tribal region, said two army officers and an area intelligence official. All three spoke on condition of anonymity because they were not authorized to speak to media.

The officials said they received reports from local authorities about the casualties. The local intelligence official said the militants used rockets and assault rifles in the attack.

A local resident, Haji Sakhi, said he heard gunshots Wednesday, and on Thursday saw some of the casualties — apparently militants.

"The fighting stopped after midnight, and today I saw several bodies in an open area of Loi Sam," he said.

The militant attack comes two days after a Taliban spokesman held a news conference in Bajur threatening homicide bombings and other attacks unless the government ended a military crackdown in another region of Pakistan's volatile northwest, Swat Valley.

Maulvi Umar, an aide of top Pakistani Taliban leader Baitullah Mehsud, threatened militants would target the government and senior officials.

Pakistan's tribal regions are considered havens for Taliban and Al Qaeda-linked fighters, many of whom are involved in attacks across the border in neighboring Afghanistan.

Bajur is the same tribal region where Usama bin Laden's No. 2, Ayman al-Zawahri, is believed to have survived a missile strike by a CIA Predator drone in 2006.