Suspects were planning an attack as early as December 1 on orders from ISIL in Iraq or Syria, Paris prosecutor says.

A “large-scale attack” in France has been thwarted, after four long-time friends in their 30s, living in the city of Strasbourg and communicating through a closed phone line were arrested, Paris prosecutor Francois Molins said.

The suspects were planning a “terror” attack in the country as early as next week on orders from an Islamic State of Iraq and the Levant (ISIL, also known as ISIS) group member in Iraq or Syria, Molins said on Friday.

The “commando” of four arrested on Sunday, in the eastern city of Strasbourg, plotted to carry out an attack on December 1, but investigators have not yet determined “the specific chosen target among all those considered by the group.”

Watch: Does France’s foreign policy make it a target?

The prosecutor did not name any targets, but security was tightened this week at the Paris headquarters of France’s criminal investigations police, which was reportedly among the locations studied.

French President Francois Hollande said a “large-scale attack” was thwarted.

The night they were arrested, two of the Strasbourg group had just downloaded the Periscope application, which allows people to stream live on the internet with a mobile phone.

The app activity suggests they were preparing an “imminent” attack, Molins said.

The four Strasbourg suspects also were in possession of guns and ammunition, he said.

Among the weapons seized during home searches were two handguns, two automatic rifles, several cartridge clips and dozens of cartridges of different calibres.

Investigators also found instructions for a money transfer, GPS coordinates and detailed explanations for obtaining more weapons on one suspect’s USB stick.

A fifth suspect was arrested in the southern city of Marseille at the same time as the Strasbourg suspects.

Remote guidance

Molins told reporters the suspect that was arrested in Marseille was not in direct contact with the other four, but was “given guidance remotely” from the same ISIL member.

All five men had a “clear will to find and to identify targets to commit an act in the very short term,” Molins said.

In addition, the five “had common instructions to obtain weapons, instructions given by a person from the Iraqi-Syrian zone through encrypted applications popular among terrorists,” he said.

Investigators also recovered a notebook that contained 12 pages of writing that referred to an armed campaign, death in martyrdom and Abu Bakr al-Baghdadi, the ISIL leader, the prosecutor said.

After being held in custody since Sunday, the five were moved on Friday to the Paris court, where they were scheduled to appear before counterterrorism investigating judges.

The Paris prosecutor asked magistrates to hand the five men preliminary charges of taking part in a “terrorist criminal association” and to jail them.

Molins was speaking the day after anti-terrorism authorities took the unusual step of holding the men in custody without charge beyond the normal maximum period, relying on a recent anti-terrorism measure.

The four arrested in Strasbourg were two French citizens, both age 37; a 36-year-old Franco Tunisian; and a 35-year-old Franco Moroccan.

Two of the men had several criminal convictions in France, Molins said. The man arrested in Marseille was a 26-year-old Moroccan.

Two of the Strasbourg suspects travelled to the Turkish-Syrian border via Cyprus, in March 2015, the prosecutor said.

The Marseille suspect left Morocco in 2013 and made multiple trips across Europe with fake ID documents.

In 2015, the Turkish authorities prevented him from entering Turkey, he said.

France remains under a state of emergency imposed after ISIL attacks in Paris in November 2015 that killed 130 people.