Isnt illegal for the police to search someone unless the police have reasonable suspicion that she/he is carrying a gun or knife 6 inches or longer? I think this is called the "Terry Pat down" law.
I remember reading this on erowid:
http://www.erowid.org/freedom/police/police_consent1.shtml and below is some interesting and relevant info from the erowid link.
"WHAT A POLICEMAN CAN NOT MAKE YOU DO
Police are not allowed to frisk for anything except weapons. If, during a weapons pat, an officer discovers something 'suspicious' you don't have to show it to them.
Although the police have been given a lot of leeway to 'check for weapons', the Supreme Court has ruled (in the key decision Minnesota v Dickerson, 1993) that a weapons search may not be used as a pretext for a more general search. In Minnesota v Dickerson, a man was stopped coming out of a 'notorious crack house' and was patted down in a 'Terry Stop'. The officer noticed something in the man's pocket which he said 'felt to be a lump of crack cocaine in cellophane'. He reached in the defendant's pocket and found some crack-cocaine. The Supreme Court ruled that in order to determine whether the item was crack or not required a further, unwarranted search was necessary which was not acceptable by 4th Amendment standards.
Police are not allowed to search everyone (see Ybarra v. Illinois, 444 U.S. 85 (1979). In Ybarra v. Illinois, a man was patted down in a bar where the police were arresting a bar owner for selling heroin. An officer identified "a cigarette pack with objects in it" in the man's pocket during the pat down and decided to search Ybarra. The High Court ruled that the officer overstepped his authority by searching everyone in the bar, even though they had a warrant to arrest the bartender and search the bar for evidence of drug sales.
A common situation where police attempt to search many individuals without probable cause is a raided party. Sometimes police tell people to 'empty your pockets' or they pat everyone down as they are leaving or they target a few people based on appearance for a full blown search. Most raids on parties are done without a judge-issued warrant and are based on noise complaints, city ordainances about event sizes, etc. In these cases, most searches will be citizens 'voluntarily' complying with requests except in the case of violence, extreme intoxication, or obvious criminal activity. Be polite and considerate of the difficult job the LEO's have, but do not consent to any warrantless search and do not offer information to the police regarding any criminal activity they suspect you of."