Tahoe -
Operation Paperclip brought them here. At the time, there was a reaction to war and the atrocities of the Nazis by the more left in this country that created a hostile environment for these scientists. They did not want them in this country. They were wanted by the Army; they were despised by many in the more elitist circles in this county at a time when we were war weary.
They all applied to come to the United States, signed an agreement for their stay in the United States, if they performed well under the agreement - they were set on the first path to citizenship, and most became citizens.
The lefties didn't want them here. Some of our more liberal scientists didn't like them. The Navy was given the preeminent role in developing rockets and they worked for the Army. I imagine many were bored at Fort Bliss and felt unappreciated at Kraut-hill Alabama. I am sure many were homesick. I am sure some of the more Nazi-involved of the bunch felt like they were in danger of being tried as war criminals, especially with the loud fringey sentiment against them coming here.
Once the Navy failed at getting a rocket up and Sputnik was launched, these guys promised and delivered a satellite in months.
As to your specific question, it depends on a lot of factors. If they were spies during wartime (WWII/Korea), they would have been picked up by the Army, tried by a secret military tribunal, and electrocuted. The Supreme Court (EX PARTE QUIRIN, 317 U.S. 1 (1942)) --
The Link -- permitted their trial by the military and found unlawful combatants (spies) were subject to a quick execution.
If they were citizens, I doubt they would have been allowed to emigrate to an enemy land if they had our military secrets. They would have been arrested for espionage, tried in a civilian court and been sent to prison.
If they were working under an immigration agreement, they would have been detained as posing a threat to national security until the threat passed (could have been indefinite).
But all of that is based them having information the Soviets wanted and a threat that they would go to the Soviets (or the Soviets picking them up). They were in Germany - not in custody - before they came to the U.S. so it's hard to create a scenario similar to this one. They were watched, I'm sure, in Germany to protect them from the Soviets. We "rescued" family members from the Soviet occupied Germany surreptitiously. The families came to the U.S. with them.
With the ruling today, they would be subject to DHS statutes/regs/administrative procedures. Aliens are subject to administrative proceedings and mandatory deportation orders. There is a kink in the law that requires release after a deportation order, except in special circumstances. If we had a nuclear scientist of Iranian citizenship who was trying to go back to Iran from this country after working in nuclear technology, he would be detained and the government would work for indefinite detention based on the threat he posed.
He would have habeas rights because he was in this country. Habeas requires proof that the detention is lawful, which takes into account necessity). Detention does not necessarily mean a crime was committed in the national security context (and pursuant to legislation by Congress).
The difference? It depends on the circumstances. Would EX PARTE QUIRIN, 317 U.S. 1 (1942) be followed by this Supreme Court? Hard to say. Kennedy is the swing and he moves with the wind. It would be 5-4 and my guess is the German saboteurs executed in that case wouldn't have been executed and would be called POW's by the Court, not unlawful combatants (as they called them in 1942).