The situation at the airport is a little different that someone walking down the street.
When I buy an airline ticket, I have consented to a search of my person and my luggage. In fact, I will not fly unless I am certain that every other passenger has also consented to an equivalent search.
Honestly, I don't know where in the ticket-buying process I have consented. It is probably in the fine print somewhere.