A knife-wielding man has been shot dead in the center of Brussels after attacking a group of soldiers, injuring two of them, the Belgian authorities said.

The man shouted “Allahu Akbar” (‘God is great’ in Arabic) twice while carrying out the attack, according to federal prosecutor’s office spokeswoman Esther Natus.

“We do consider it a terror attack,” AP quoted Natus as saying.

The soldiers were lightly wounded in the attack, which happened in the Belgian capital at about 8:15pm local time (6:15pm GMT). One was cut in the face, while the other suffered an injury to the hand.

In an update on Saturday, the prosecutors said the attacker was identified as a 30-year-old man from Somalia, who arrived in Belgium in 2004 and became a Belgian citizen in 2015. He had a fake firearm and two copies of the Koran at the time of the attack, the statement said.

Investigators searched the home of the attacker in Bruges, but would not disclose what they found there.

#BREAKING Soldiers shot a man who attacked them with machete in Brussels: Belgium media pic.twitter.com/sKH4CfKlOs — Guy Elster (@guyelster) August 25, 2017

The prosecutors said the man was not considered a terrorist threat and apparently acted alone. He has a criminal record for battery.

A man attacked soldiers in Brussels with a machete tonight. Pics I took in the street. #Brussels#Brusselsattack#Bruxellespic.twitter.com/LqDmXFnLa2 — Thomas da Silva Rosa (@tdasilvarosa) August 25, 2017

Large numbers of police officers were deployed to the scene, which was cordoned off. The mayor of Brussels and the federal prosecutor also arrived at the scene.

Le parquet fédéral va descendre sur place. Le suspect a été neutralisé alors qu’il menaçait deux militaires d’un couteau #Bruxellespic.twitter.com/1adVATgzMw — BX1_Actu (@BX1_Actu) August 25, 2017

Belgian Prime Minister Charles Michel expressed “all our support to our soldiers” in a Twitter post. “Our security services stay vigilant and we monitor the situation closely,” he said.