The U.S. Supreme Court has held that a public school official's search of a student is constitutional if it is "justified at its inception" and "reasonably related in scope to the circumstances which justified the interference in the first place." This search was neither.
When Wilson ordered the search, the only evidence that Savana had violated school policy was the uncorroborated accusation from Marissa, who was in trouble herself and eager to shift the blame. Even Marissa (who had pills in her pockets, not her underwear) did not claim that Savana currently possessed any pills, let alone that she had hidden them under her clothes.
Savana, who was closely supervised after Wilson approached her, did not have an opportunity to stash contraband. As the American Civil Liberties Union puts it, "There was no reason to suspect that a 13-year-old honor-roll student with a clean disciplinary record had adopted drug-smuggling practices associated with international narcotrafficking, or to suppose that other middle-school students would willingly consume ibuprofen that was stored in another student's crotch."
The invasiveness of the search also has to be weighed against the evil it was aimed at preventing. "Remember," the school district's lawyer recently told ABC News by way of justification, "this was prescription-strength ibuprofen." It's a good thing the school took swift action, before anyone got unauthorized relief from menstrual cramps.