Militants attacked the American University of Afghanistan on Thursday, killing at least one person and wounding another 18, officials said, adding that security forces were still combing the campus in search of attackers.
AP photographer Massoud Hossaini 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 said at least two grenades were thrown into the classroom, wounding several of his classmates.
Hossaini and about nine students later managed to escape from the campus through an 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 other students took refuge in a residential house near the campus, and were later safely evacuated by Afghan security forces.
Hedayatullah Stanikzai, an official with the Ministry of Public Health, said a guard employed by the university had been killed and that the wounded included a foreign teacher. University authorities could not immediately be reached for comment.
University President Mark English earlier told The Associated Press that security forces had arrived on the scene soon after the attack began around 7 p.m. (1430 GMT), saying "we are trying to assess the situation."
Dejan Panic, the program director at Kabul's Emergency Hospital, said 18 patients, including five women, had so far been admitted. He said three were "seriously" wounded, probably from automatic gunfire.
Police spokesman Sediq Sediqqi said security forces were conducting a clearing operation to track down the "terrorists." He said it was still not clear if there were one or two attackers.
All other personnel on the campus were being evacuated, he said. He had no further details on the nature of the attack.
The Pentagon said U.S. military advisers were on the ground with Afghan security forces at the university. Spokesman Adam Stump said the forces had been embedded with the Afghan units.
The attack on AUAF comes two weeks after two university staff, an American and an Australian, were kidnapped from their car by unknown gunmen. Their whereabouts are still unknown.
The university was established in 2006 to offer liberal arts courses modeled on the U.S. system. More than 1,000 students are currently enrolled in degree courses.
The Taliban have been fighting to overthrow the Kabul government for 15 years, and regard foreign civilians as legitimate targets.