At least seven people were killed and eight others wounded after a suicide bomber struck a vehicle carrying prison employees on the outskirts of the capital on Wednesday, officials said.
"The suicide bomber, who was trying to pass through the security checkpoint of the prison, was identified by the police around two kilometres from the prison compound where he detonated his explosives before reaching his intended target," said a statement by the Interior Ministry's General Directorate of Prison and Detention Centres.
The statement cited by Efe news confirmed the toll.
Earlier, Tolo News cited Interior Ministry spokesperson Najib Danish as saying that three security force members and three civilians were among the dead.
Mohammad Anees, an eyewitness, said the powerful explosion took place in front of the prison's gate where a number of visitors were waiting to pass a rigorous security check before entering.
No group claimed responsibility for the attack.
Over the past few months, Kabul has witnessed waves of terror attacks by the Islamic State (IS) outfit and Taliban insurgents.
More than 2,790 civilians were killed and over 5,250 others injured in conflict-related incidents in the first nine months of the year in the war-torn country, according to figures released by the UN mission in the country.
(With inputs from agencies.)