"A reasonable police officer would have known that attempting to obtain a photograph of a minor child's erect penis, by ordering the child to masturbate in the presence of others, would unlawfully invade the child's right of privacy under the Fourth Amendment," the U.S. Court of Appeals for the 4th Circuit declares in a decision it issued on Tuesday. It is hard to argue with that conclusion (although a dissenting judge did). It is even harder to imagine the circumstances that made it necessary.

As Robby Soave noted at the time, the story started with a video that Trey Sims, a 17-year-old Virginia boy, sent to his 15-year-old girlfriend in 2014. According to David E. Abbott, the Manassas detective who handled the case, the video showed Sims "fondling his erect penis," making Sims guilty of producing child pornography, an offense in which he was both victim and perpetrator. While investigating this supposed crime, Abbott obtained a search warrant authorizing him to take "photographs of the genitals, hands, and other parts of the body of Trey Sims that will be used as comparisons in recovered forensic evidence from the victim and suspect's electronic devices." The warrant explicitly covered "a photograph of the suspect's erect penis."

Abbott and two uniformed, armed officers executed the search warrant in the locker room of a juvenile detention center, where Abbott ordered Sims to "pull down his pants so that photos could be taken of his penis." Abbott then instructed Sims to "use his hand to manipulate his penis in different ways" so the desired photograph of an erect phallus could be obtained. When "Sims was unable to achieve an erection," Abbott "took photographs of Sims' flaccid penis using Abbott's cellular telephone."

Unsatisfied with that picture, Abbott obtained a second warrant for another photo shoot. But before he could serve it, the publicity generated by complaints from Sims' lawyer led the Mannassas City Police Department and Prince William County Commonwealth's Attorney Paul Ebert to condemn Abbott's methods. Claiborne T. Richardson II, the assistant commonwealth's attorney who had approved both search warrant applications, announced that the second warrant would not be executed and that the photographs Abbott had already taken would not be used as evidence against Sims.

The juvenile court reduced the charge against Sims to felony possession of child pornography; that charge was dismissed after Sims completed a year of probation. But that was not the end of the case. Sims' family hired Victor Glasberg, an Alexandria civil rights attorney, who helped them file a federal lawsuit under 42 USC 1983, which allows people to recover damages from police officers and other officials who violate their constitutional rights. Because "Abbott died before the present case was filed," Sims sued the administrator of his estate, along with Richardson.

The 4th Circuit does not mention how Abbott died, but it seems relevant in understanding his treatment of Sims. Abbott shot himself outside his home in December 2015 after Prince William County police arrived to arrest him on suspicion of molesting two boys he met as a youth hockey coach. "In spite of these recent developments regarding the serious allegations against him," the Manassas City Police Department said, "we are grateful for the contributions Det. Abbott made during his time with Manassas City Police." His contributions included investigating sex offenses as a member of the Northern Virginia-Washington D.C. Internet Crimes Against Children Task Force.

U.S. District Judge Claude Hilton dismissed Sims' lawsuit, finding that Richardson was protected by absolute immunity as a prosecutor and that Abbott was protected by qualified immunity because the actions described by Sims did not violate any clearly established constitutional rights. The 4th Circuit disagreed with the latter conclusion. "Both the outrageous scope of the sexually intrusive search and the intimidating manner in which the search was conducted weigh strongly against any finding that the search was reasonable," Judge Barbara Milano Keenan writes in an opinion joined by Judge Albert Diaz. "We cannot perceive any circumstance that would justify a police search requiring an individual to masturbate in the presence of others."

Since there was already enough evidence to sustain the charge against Sims, Keenan says, the "exceptionally intrusive" search was not just excessive but entirely gratuitous. "Because there was no justification for the alleged search to photograph Sims' erect penis and the order that he masturbate in the presence of others," she writes, "we conclude that well-established Fourth Amendment limitations on sexually invasive searches adequately would have placed any reasonable officer on notice that such police action was unlawful."

While allowing Sims to proceed with his claim under 42 USC 1983, the 4th Circuit said Judge Hilton was right to dismiss Sims' claim under 18 USC 2255(a), which authorizes lawsuits by victims of child pornographers. Abbott's pictures of Sims would qualify as child porn only if they were produced with "lascivious" intent, Keenan says, and "Sims did not plausibly allege that Abbott acted with the purpose of sexually exciting himself"—a questionable judgment in light of the charges that drove Abbott to suicide.

Writing in dissent, Judge Robert King says Abbott's humiliating treatment of Sims—supposedly justified, lest you forget, by a crime that Sims committed when he took a video of himself—was entirely reasonable, as reflected in the search warrants approved by a prosecutor and two magistrates. "Detective Abbott was acting pursuant to the advice of counsel and adhering to a court order," King writes. "In my view, Abbott's actions were entirely consistent with applicable law and the Fourth Amendment….When a judicial officer—such as a state court magistrate—has issued a search warrant upon probable cause, specifying therein that which is to be searched and seized, it is unreasonable to require the officer charged with executing the warrant to reject the judicial decision and disobey the court's directive."

King's framing of the issue obscures the facts that it was Abbott, in consultation with Richardson, who sought the warrant to begin with, and that it was Abbott who chose to execute the warrant in a particularly degrading manner, all of which seems even creepier given the circumstances of the detective's death. Abbott's actions were so outrageous that his superiors and Richardson's boss swiftly repudiated them once the story went public. The fact that two other police officers, a prosecutor, and two magistrates nevertheless deemed them reasonable is not a defense of Abbott. It is an indictment of his accomplices.