Morocco has announced the arrest of two suspected members of the Islamic State group.

The statement Friday said the men, who had connections to foreign extremists, were planning to train in Syria with the group before returning to carry out attacks in Morocco.

The announcement comes as the Moroccan military is on high alert, stationing anti-aircraft missile batteries around major cities, as well as along the borders with Algeria and Mauritania.

There has been no official explanation for the sudden very visible presence of military units around the country but the local press has said it is in response to fears of a terrorist attack.

Morocco says at least 1,000 of its citizens are fighting on the side of Islamic extremists in Syria and Iraq.