An Afghanistan-based militant group called Hafiz Gul Bahadur claimed responsibility for the deadly attack.
A suicide bomber rammed a vehicle loaded with explosives into the boundary wall of a military base, killing at least eight Pakistani soldiers.
Insurgents attacked an army outpost in Bannu, on the border with the North Waziristan tribal region, and the army said in a statement on Tuesday that soldiers had killed all 10 attackers involved.
“This timely and effective response averted a catastrophe and saved precious and innocent lives,” it added.
Seven army soldiers and one paramilitary soldier were among those killed in Monday’s attack.
“Pakistan Armed Forces will take all necessary measures as deemed appropriate against any such threats emanating from Afghanistan,” the army said.
The attack was claimed by the Pakistani Taliban-affiliated group Hafiz Gul Bahadur (TTP), which the military said was based in neighbouring Afghanistan and was “planning terrorist acts inside Pakistan”.
The British colonial-era base, historically used as a base for counterinsurgency operations, is surrounded by civilian homes which were shaken by Monday’s explosion, Reuters reported, citing two unnamed local officials.
The initial explosion caused the perimeter wall to collapse, allowing other fighter jets to enter the base.
A local official, speaking on condition of anonymity, also told AFP that 141 people were wounded after fighters wearing suicide vests “entered residential areas” in a 26-hour battle with guns and rocket-propelled grenades.
Suspected TTP militants carried out a fresh attack in Dera Ismail Khan area near Bannu on Tuesday morning, killing two security personnel and three assailants.
Pakistan’s military launched an unprecedented cross-border operation targeting the militant group in March.
Islamabad says it has consistently raised the issue of cross-border attacks with the Taliban regime, which does not allow it to use Afghan territory for attacks.
The incident has increased tensions between the neighbouring countries and led to clashes between border guards.
The attack also came weeks after a surge in violence prompted Prime Minister Sharif to announce a new, major operation to root out militant groups.