I cheerfully consent (of course I do, what choice is there)
You can say "No". One simple word that, in defiance of authority behaving stupidly, has a long and proud history.
And one thing to keep in mind (especially on airlines, as you were describing)... if you refuse a consensual search, and they deny you boarding privileges, you should be entitled to a full refund of the fare in question without penalties or holdbacks. After all, the security officer is the duly authorized agent of the airlines (yes, it's true), and if the airline doesn't want to allow you on board for its own particular reasons, then it has to refund your payment in full.
I've seen people who wanted to cancel their flights, but do so without penalty, do precisely this in order to get their expensive airfare back. Go the airport on the day of, and refuse to be searched or screened. You'll have to stand up strong in face of a lot of people who are telling you what a jerk you are, and "don't you get it", blah blah blah... but it can be done.