Several others were wounded including the head of the religious school, Maulana Hamid-ul-Haq, son of the late Maulana Sami-ul-Haq, considered the father of the Taliban.
Regional police officer Najeebur Rahman said Haq was in critical condition.
Tucked away in a dusty Pakistani town off the main motorway to the Afghan border, Darul Uloom Haqqania university was the launch pad for the Taliban movement in the 1990s and is still often described as an incubator for radical Islamists.
No group has claimed responsibility for the attack.
Pakistan is battling twin insurgencies, one mounted by Islamists and the other by ethnic militants seeking secession over what they say is the government’s unfair division of natural resources.