A FORMER senior officer in Spain’s National Police Corps has said the 2017 terror attacks in Barcelona and Cambrils were organised by the country’s secret service in a bid to destabilise Catalonia before the independence referendum there.

However, Jose Manuel Villarejo said the attacks in August that year – which included a truck running over pedestrians on La Rambla in Barcelona – “were a serious mistake” on the part of former National Intelligence Service (CNI) director Feliz Sanz Roldan.

Ahead of the October 2017 indyref, the former commissioner said the CNI boss “wanted to give Catalonia a fright, but miscalculated the consequences”.

A total of 16 people died in the attacks – known as 17-A – including a woman who died as five members of the jihadist cell launched a knife attack on the beachfront at Cambrils, having driven there the day after the Barcelona attack.

All five men were shot dead by police. Three men who helped in the attacks were last year sentenced to jail terms of between eight and 53 years.

It later emerged that the alleged mastermind of the attacks, an imam in the city of Ripoll, was a CNI informant.

Villarejo has been involved with numerous “secret” operations with the CNI.

He has spent more than three years in custody and his remarks were made in court during a case involving police spying allegations.

The former commissioner said he could prove everything he had claimed: “All the evidence is in my archives. I authorise their release.

“We must think that the citizenry is not a minor and the law of secrets cannot be used to hide everything. It is an obsolete Francoist law from 1968.”

His claims triggered anger in Catalonia, where the government was considering a legal response.

Catalan President Peres Aragones said on social media: “17-A was a barbarity that has marked us forever. And if Villarejo’s words are true, explanations are needed now.

“We know very well how the state sewers work, so we demand that they be investigated in order to clarify the truth.

“I have also asked the legal services of the Generalitat [government] to study these statements and the relevant legal actions that can be taken. For the truth. For the victims, for the Catalans and for all those who are on the side of peace and democracy.”

In radio interviews, his vice-president, Jordi Puignero, said the Spanish state wanted to clarify Villarejo’s allegations over the CNI and the terror attacks, and has urged them to mount an investigation.

He also expressed concern that no-one from the state had so far contradicted his statements, or said they would be investigated.