Why was it a problem in the first place having illegal immigrants working?

No really, I do wonder.

* Americans probably have some sort of social security number.
* Tie the salary to the social security number.
* Crack down hard on companies trying to circumvent it.

Problem solved.

Not only does it work against illegal immigration, but also people working without paying taxes.