For the past week the European media has focused on a terrorist cell of men of Moroccan heritage who used a van and a car to mow down and kill 14 people in two attacks in northern Spain. The attacks took place in Barcelona, one of Europe's favourite tourist destinations, so they clearly merit a lot of coverage. But the facts of the case are depressingly familiar.
The terrorists were technically incompetent – they blew up their hideout and their recruiter, an imam called Abdelbaki Es Satty, in an accident that set off the gas canisters they were planning to use in a spectacular attack. One of the possible targets was the fantastical Sagrada Familia church, under construction for 135 years and unlikely to be completed before 2030.
Fearing exposure after the explosion, they set about killing people in the crudest possible way. The only thing certain about the group's goals is that they all wanted to die. They wore fake suicide vests so that when cornered by the police they would be shot dead. Younes Abouyaaqoub, the driver of the van that killed 13 in Barcelona, fled from the scene, but he had no plan of escape. He was found wandering without money.
So there is much in this cell's activities that is similar to previous vehicle-based attacks on crowds in Europe. While they were clearly terrorists, it is hard to escape the conclusion that the roots of their motivation was the spiritual redemption of second generation Muslim immigrants who are confused about their identity. Friends recalled Abouyaaqoub as "calm, quiet and shy" and a good student, just the sort of person who seems most likely to fall under the spell of a preacher promoting a death cult.
Aside from these familiar tropes, there is an issue that concerns European security officials as they face random attacks from ISIL-inspired terrorists at the same time as continuing high migration flows from North Africa.
More from Alan Philps:
> Trump must heed the lessons of Charlottesville
> Hizbollah, Assad and his Iranian masters
For years, Morocco has been a cornerstone of stability in North Africa and is seen in Europe as an Arab country of rare cohesion. There is some truth to this exceptionalism. King Mohammed VI defused the Arab Spring protests in 2011 with adroit political concessions. Since 2015, the Moroccan security services have been professionalised with the creation of the Central Bureau of Judicial Investigations, a sort of FBI clone.
This has been successful in rounding up ISIL recruiters and sympathisers. It claims to have provided European countries with key intelligence, including leading the French police to the location of the hideout of Abdelhamid Abaaoud, the Belgian-Moroccan terrorist responsible for the Paris attacks of 2015.
At the same time, Morocco has restrained the flow of migrants across the Strait of Gibraltar thanks to what European officials delicately describe as incentives offered to those in charge of the ports.
The effectiveness of these arrangements, however, is now being cast into doubt, raising fears in European officials that their partner in a chaotic North Africa may be less reliable in the future.
The flow of migrants into southern Spain from Morocco has shot up. Some 2,300 migrants made it to Spain in July, more than four times as many as a year earlier, according to the Frontex, the European border agency. This may be due to restrictions on the migrant route from Libya to Italy which have been imposed at the behest of Italy, the destination of by far the largest number of arrivals from Africa. So the pressure on the Moroccan ports is clearly growing.
More from Opinion:
> What ISIL's rise in 2014 tells us about Al Qaeda's potential
> The nuclear deal has failed to curb Iran's weapons programme
The question being asked is whether the Moroccan security services are as firmly in control as in the past. This is prompted by protests that began last year after a fisherman was crushed to death in a rubbish truck after he dived in to recover his stock of swordfish, which had been confiscated. This macabre incident, followed by a furious crowd that caught it on video, prompted anger through the mountainous Rif area on Morocco’s northern coast.
The protests have spread from Rif to other parts of the country and the concern in Europe is that the Moroccan security services may be occupied more with events at home than the interests of European neighbours.
These fears coincide with European concerns about where the ISIL recruits are going to go when the Syrian city of Raqqa is liberated. The Moroccan recruits to ISIL are estimated at 1,600 by to the Rabat authorities plus a further 2,000 who also hold European passports.
When there is no territory controlled by ISIL – its attempt to colonise a part of Libya was quickly crushed – Europe looks like the most likely destination for the defeated recruits. So the Barcelona terrorist cell is not just a local incident but may be the sign of what awaits Europe. And the next time could be far more devastating.
Follow The National's Opinion section on Twitter