Christmas market (illustration) By: Chan Yuan

(Scroll down for video) A young boy was detained after he planned to blow up a Christmas market and city hall in Germany, according to police.

Ludwigshafen police said that the 12-year-old boy, who was born to his parents of Iraq, after trying to detonate two bombs in order to cause mass casualty events.

Eva Lohse, who is the mayor of Ludwigshafen, said that the boy was taken to a safe place where he is no longer a threat to the public.

Investigators said that a passerby prevented the bomb from exploding outside city hall after noticing an abandoned backpack and calling the police.

The backpack contained firecrackers, nails and glass. The first bomb did not explode at the Christmas market due to a malfunction.

According to the police investigation, the boy, who was born in Germany to two Iraqi parents, has been radicalized by Muslim extremists.