The problem seems to be the assumption that people from a particular country, or of a particular religion, share a common set of beliefs.
@Derec is fond of pointing out that 99% of Afghans have beliefs that are incompatible with Western values, and then concluding that therefore Afghans should be prohibited from emigration to the West.
The problem (as I am sure you are aware) with this (assuming
ad argumentum that it is true) is that it implies denying escape from radical Islam to the 1% (~420,000) of Afghans who are opposed to redical Islam, and currently stuck in a country where radical Islam is massively dominant.
US and EU immigration law currently (or at least until Trump started unilaterally dictating US law) treats applicants for migration as individuals. The details of what constitutes grounds to accept or deny such an application may be sensible or daft; But regardless, they are applied on a case by case basis. Nobody is denied entry solely because they are Afghan; And (contra
@Derec) that should remain true even if policy becomes to deny entry to radical Muslims, because 99% is less than 100%.
Banning Nazis from entering Germany is a German prerogative; But banning Austrians on the assumption that all Austrians are Nazis is idiotic, illiberal and immoral (and quite possibly other things beginning with "i"), unless there is hard evidence for the claim that
all Austrians are Nazis. The fact that
most Austrians are Nazis is not sufficient, even if true.
The shortcut of assuming that all members of a given nationality, citizenship or ethnicity will agree on some political or religious position is commonplace; But it's untrue, and bigoted.
Fairness demands that we treat each individual as an individual, and seek to learn his particular political and religious views before rejecting him. All the more so if those views are at odds with the majority of his countrymen, and are dangerous to express in his present location.
"Muslim" is not a single immutable set of beliefs. To determine whether an individual is a threat, we need to know far more about him than just that he calls himself a Muslim.