Spanish former police chief admits that the Spanish secret services (CNI) were behind the jihadist attacks in Barcelona, August 2017. Their intention was ‘to scare Catalonia just before the independence referendum.’ 16 people from various nationalities were killed.
It doesn't go into detail what "were behind" means. I found this article on catalannews.com which contains more details, but is also vague on the CNIs exact involvement (it describes the actions as "miscalculation" and "serious mistake").
It also mentions that the alleged mastermind behind the attacks was a CNI informant, but as far as I know that isn't new information.
So it's not exactly clear to me what is being alleged. Was the attack originally the CNIs idea? Did the CNI help plan the attack? Did they know of the attack beforehand and willingly let it happen? Or did they not know of the attack, but had some connection to the terrorists?