Austria's interior minister has admitted that a warning from Slovakia last summer about a gunman who went on the rampage in the centre of Vienna was not followed up.
Four people were fatally shot and 23 others wounded on Monday night.
Police in Slovakia revealed they had tipped off Austrian authorities about "suspects from Austria" trying to buy ammunition in July.
Reports suggest the trip to buy bullets failed as the gunman had no licence.
It has also emerged he was released early from a jail sentence last December for trying to join jihadists in Syria.
According to German media, the 20-year-old, who was shot dead by police nine minutes after the attack began, travelled to neighbouring Slovakia to buy ammunition for a Kalashnikov AK-47 assault rifle but returned empty-handed.
Slovak police said they had informed their Austrian colleagues immediately, adding they would not comment further.
Asked about the revelations on Wednesday, Austrian Interior Minister Karl Nehammer said the information had been investigated by the BVT domestic intelligence agency but no further action had been taken.
"Something obviously went wrong in communication," he told reporters, adding that he wanted an independent inquiry to find out why.
Who were the victims?
More details have emerged about the four people murdered in the centre of Vienna in the hours before new coronavirus restrictions were due to come into force:
- A 24-year-old German student was killed in front of the restaurant in Ruprechtsplatz where she worked as a waitress; she'd been studying at the nearby University of Applied Arts
- A 21-year-old man originally from North Macedonia was shot near Fleischmarkt; Nedzip V. was described as a painter who loved football and played for years for local club FC Bisamberg
- A 39-year-old Austrian man was killed in front of a fast food restaurant in Schwedenplatz
- A 44-year-old Austrian woman died later in hospital of her wounds. Reports said she worked nearby for Vienna-based company Tribotecc
Among the 23 people wounded in the attack, 13 suffered bullet wounds and seven are in a serious condition. Most are from Austria, but some are from Germany, Slovakia, Luxembourg and other countries. One of those in a serious condition was also a student at the university of applied arts, known as Die Angewandte.
Austrian authorities say the killer was armed with an automatic weapon, a pistol and a machete as well as a fake explosive belt.
They were initially unsure if there had been more than one gunman, after Monday night's attack which lasted nine minutes across six crime scenes.
But the interior minister confirmed on Wednesday that he had acted alone, as a review of videos received by police was now complete. Jihadist group Islamic State (IS) claimed on its propaganda outlet Amaq that it was behind the attack.
The centre of Vienna began returning to normal on Wednesday and Mayor Michael Ludwig held a minute's silence in memory of the victims, as Austria marked a second day of mourning.
Fourteen people have been detained in Austria who were linked to the gunman and the interior minister said they were aged 16 to 28 and with a migrant background.
Swiss police have arrested two others and Justice Minister Karin Keller-Sutter has alleged that the pair had been "colleagues" of the gunman. "The three men also met in person," she told St Galler Tagblatt.
The conduct of Austria's BVT intelligence agency has come under direct attack from Herbert Kickl, the former interior minister when the far-right Freedom Party was part of the coalition government that collapsed in May 2019.
But the current interior minister said the BVT agency had been profoundly damaged, if not destroyed, while Mr Kickl was in office.
Kurz calls for European action
Austrian Chancellor Sebastian Kurz has responded to the Vienna attack by urging the European Union to "focus much more strongly on the problem of political Islam in the future". He said he had spoken to France's Emmanuel Macron and many others with the aim of co-ordinating more closely.
He told Germany's Die Welt: "I hope we will see an end to this misunderstood tolerance and that all countries in Europe will finally realise how dangerous the ideology of political Islam is for our freedom and the European way of life."
Elsewhere, Italian Foreign Minister Luigi Di Maio has called for an EU Patriot Act, along the lines of the US law which increased surveillance powers after the 9/11 attacks. "Europe and Italy itself cannot continue with just words," he said, referring to the attacks on Vienna and on Nice last week. The Nice attacker had travelled from Tunisia via Italy into the south of France.
MEP Antonio Tajani has repeated his call for a European FBI, to co-ordinate the work of police and intelligence services, working in tandem against IS militants.
What we know about the gunman
Austria's interior minister revealed that the "Islamist terrorist", named Kujtim Fejzulai, had been jailed for 22 months in April 2019 for trying to travel to Syria to join IS jihadists and freed after only eight months.
He was released under more lenient terms for young adults, after convincing the authorities that he no longer held extremist Islamist views, Mr Nehammer said.
However, the Derad association that handles a de-radicalisation programme in Austria's jails has rejected remarks by the interior minister that the gunman had "fooled" its staff into granting him an early release. He was never assessed by his supervisor as "de-radicalised", the association insisted, but had been subject to strict parole conditions.
He had both Austrian and Macedonian citizenship and relatives in North Macedonia told Reuters news agency he had been caught in Turkey two years ago and sent back to Austria.
The head of public security, Franz Ruf, confirmed later that Fejzulai had entered Turkey on 1 September 2018 and had been arrested as a "foreign fighter" on his return to Austria in January 2019.