I did it once back in 2008 for a flight from Costa Rica to Switzerland via Miami and was caught completely by surprise that, unlike every other airport in the world I have been prior, Miami (US in general?) did not have a separate transit area, and that I had to go trough the whole customs and migration circus for a 3 hour layover.
Which is a shame there parts of the US I'd love to see but not at the price of entry.
Government laws always will overturn any agreement you had with an employers or some other person or organization.
Security theater or not, if a country is being an asshole in foreign affairs, or at least is at war with someone, be sure your rights most probably will be violated if you decide to have an interaction with such government employees.