I think it's too late for this "solution" (which is not anyway, imho).
People who led those attacks were already here in Europe, some even first or second generation immigrants.
they're not coming to Europe risking death on boats or walking across deserts like real refugees, they have passports, multiple citizenships, they live here.
That's the scary thing and that's what makes so difficult to prevent their attacks.
Now, thats the problem. When legal immigrants and not illegal immigrants post a threat.