Gunmen have attacked a university in northwest Pakistan with reports of security forces battling it out with the assailants inside the building.

The ongoing assault began on Wednesday morning at the  Bacha Khan University in Charsadda, about 140km from the capital Islamabad.

Hospital sources have confirmed the death of one professor while adding that at least seven people have been injured.

Al Jazeera’s Kamal Hyder, reporting from Islamabad, said initial details were scarce and that security forces’ operations were hampered by heavy fog.

“According to police sources, three attackers entered the university of about 3,000 students. Eyewitnesses are saying they’ve heard two large explosions and they can still hear the gunfire.

“Elite police units and the Army have entered the compound and are trying to evacuate the students.”

Deputy Inspector General Saeed Wazir told Reuters news agency that police had moved into the building and a gunfight with the attackers was under way.

“We launched an operation inside the university and are trying to rescue the students and staff of the institution,” Wazir said.

Shabir Khan, a lecturer at the English department, said he was about to leave the hostel for the department when the shooting began.

“Most of the students and staff were in the classes when the firing began,” Khan said.

On Tuesday, a suicide bomber blew himself up close to a police checkpoint in the Jamrud area of northwestern Pakistan, killing at least 10 people and wounding more than 20.

At least 144 people, most of them children, were killed when armed men attacked the Army Public School in Peshawar in December 2014. (Al Jazeera)