Five of the asylum-seekers were detained after the attack in which ten policemen needed hospital treatment for their injuries and a police car was badly damaged.
The detained aslyum-seekers face charges of assault, grievous bodily harm, disruption of a public service and damage to a police vehicle.
The North Africans belong to a group of some 1,200 immigrants from the Maghreb whose political asylum applications were turned down.
Police believe the asylum-seekers carried out the attack in the hope of being arrested thus avoiding or deferring deportation.
They took advantage of the location of the immigration office which is not inside the Naples police headquarters and therefore less secure, police said.
All 30 North Africans have appealed the decisions on their asylum requests.