After the 9/11 attacks in 2001 happened, the Patriot Act is enacted to expand the powers of US law-enforcement departments in monitoring citizens’ information and in detaining and expelling expatriates suspected of having links to terrorism.
See: https://www.congress.gov/107/plaws/publ56/PLAW-107publ56.pdf