The American University of Afghanistan came under militant attack on Wednesday, according to an Associated Press photographer who was in class at the time.
Massoud Hossaini said he was in a classroom with 15 students when he heard an explosion on the southern flank of the campus.
"I went to the window to see what was going on, and I saw a person in normal clothes outside. He shot at me and shattered the glass," Hossaini said, adding that he fell on the glass and cut his hands.
The students then barricaded themselves into the classroom, pushing chairs and desks against the door, and staying on the floor.
Hossaini and about nine students managed to escape from the campus through a northern emergency gate.
"As we were running I saw someone lying on the ground face down, they looked like they had been shot in the back," he said.
Hossaini and the nine students took refuge in a residential house near the campus.
University President Mark English told The Associated Press that security forces had arrived on the scene soon after the attack began around 7 p.m. (1430 GMT) and that "we are trying to assess the situation."
Other witnesses say they heard explosions and automatic gunfire. Ambulances arrived at the campus in western Kabul, but it was not immediately clear how many people had been wounded.
Police spokesman Sediq Sediqqi says security forces entered the campus and "are trying to search for the terrorists." He says police are also trying to evacuate all personnel from the campus. He had no further details on the nature of the attack.
The attack comes two weeks after two university staff were kidnapped from their car by unknown gunmen. Their whereabouts are still unknown.
The Taliban have been fighting to overthrow the Kabul government for 15 years, and regard foreign civilians as legitimate targets.