The last time I flew from Canada to Singapore through the US, the US Customs officer - on Canadian soil - was hostile, asked me numerous questions about my travel, itinerary, who I was intending to meet, and my personal finances.
When I questioned if all this was necessary as I'm not even traveling to the US, he became agitated and threatened "You know I could stop your trip right here? I might not be convinced you'll actually transfer on your next flight or leave the US."
After scowling at his screen for a while, he finally scoffed, slammed my passport on the counter and said "Go." I guess he felt he had shown his power enough.
It was extremely stressful and humiliating, and I vowed never to subject myself to it again. FWIW, I'm a caucasian, middle-class Canadian IT nerd. I can only imagine what others who meet their "profile" go through.