Image
© Davide Restivo
In a field office near Brunswick, Ga., a federal agent working as an undercover cybersleuth signed on to a large file-sharing network sometimes used by traders in child pornography.

Using a law-enforcement computer program called RoundUp, the agent, Stephen D. Logan, scanned computer activity by the network's members in the state of Washington. He located a computer offering illegal photos and videos, and downloaded three files as evidence.

Local police took it from there, obtaining a warrant based on the distant search. The owner of the computer was convicted of possessing and distributing child pornography, and is now serving an 18-year sentence at a federal prison in Texas.

Had Mr. Logan worked for the F.B.I., his work on the case might have seemed routine. But Mr. Logan worked for the Naval Criminal Investigative Service, and his mission that day in April 2011, he would later testify, had been to look for military service members trading in child pornography in Washington, the location of several naval bases.

Mr. Logan's computer surveillance could not distinguish military users from others, and the man he helped catch, Michael A. Dreyer, was a civilian. Now the case has sparked sharp debate over how much the military's formidable investigative powers can legally contribute to civilian law enforcement.

This month, in a scathing rebuke of the investigative service and the Justice Department that has generated wide interest in legal circles, a federal appeals court in San Francisco overturned Mr. Dreyer's conviction. Federal authorities had shown "a profound lack of regard for the important limitations on the role of the military in our civilian society," declared the decision issued Sept. 12 by a panel of the Federal Court of Appeals for the Ninth Circuit.

Military investigators often cooperate with civilian law enforcement when tracking down, for example, a source of heroin flowing into a military base. But in this case, "they were just searching generally on the chance that they would run into someone from the military," said Erik B. Levin, the defense lawyer in Mr. Dreyer's appeal.

In addition to condemning the Navy's investigative service for overstepping regulations that have evolved from the Posse Comitatus Act of 1878, limiting the use of federal troops in law enforcement, the appeals court took the unusually strong step of excluding the computer evidence in any new trial of Mr. Dreyer.

"The extraordinary nature of the surveillance here demonstrates a need to deter future violations," said the ruling, written by Judge Marsha S. Berzon, in justifying a decision that could set the offender free. One of the three judges dissented on this aspect, saying the harm would outweigh any benefit, and some independent legal experts said that the decision to exclude evidence went against recent legal norms.

The revelations of cybersearches by the naval agency come at a time of heightened sensitivity about computer privacy and government spying.

Marc Rotenberg, president of the Electronic Privacy Information Center, a private group in Washington, D.C., called the Circuit Court opinion "interesting and significant."

"As the Department of Defense plays a greater role in domestic surveillance, questions will be asked about how its surveillance capabilities might feed into domestic law enforcement," he said.

Federal prosecutors argued that because the N.C.I.S. investigator was a civilian employee, he was not covered by the rules barring military involvement in civilian criminal investigations. They also argued that the agency had a legitimate military-related purpose in seeking child pornography offenders in a region with several naval facilities.

They added that the investigative service's role in the case - the transfer of information - involved only "indirect" and permissible involvement in civilian law enforcement. Federal prosecutors declined to comment last week, but a federal prosecutor told The Seattle Times that the judges may have misunderstood the technology Mr. Jacobs used and the scope of his searches.

The Justice Department is considering whether to appeal the ruling.

The federal appeals panel expressed its views in unusually harsh terms, at some points describing the investigative service as monitoring "all the civilian computers" in a state, although, according to court documents, the searches that led N.C.I.S. to Mr. Dreyer were apparently limited to computers linked to targeted file-sharing networks.

The naval investigative service's role in the case "amounts to the military acting as a national police force to investigate civilian law violations by civilians," Judge Andrew Kleinfeld wrote in a concurring opinion.

"Letting a criminal go free to deter national military investigation of civilians is worth it," Judge Kleinfeld wrote, defending the mandate to exclude the computer evidence in any retrial.

The third member of the appeals panel, Judge Diarmuid O'Scannlain, while agreeing that the surveillance had violated regulations, objected to the decision to exclude the evidence. "This case provides no justification for setting a convicted child pornographer free," he wrote.

Orin S. Kerr, a law professor at George Washington University, described as "aggressive" the court's decision to exclude incriminating evidence from the computer searches. The Supreme Court in recent decades has usually allowed such evidence unless a defendant's constitutional rights have been violated, which he said is not true of this case.

Charles J. Dunlap Jr., an expert on national security law at Duke University and a former Air Force general, said that the Posse Comitatus Act had been aimed at the threat the armed forces might present to democracy, and that civilian employees, like those in the naval investigative service, "simply do not pose the same kind of concerns."

The appeals court noted that evidence has rarely been excluded in past cases for violations of Posse Comitatus-related rules. But it said that the evidence of repeated violations, and the government's insistence it had done nothing wrong, warranted sending a strong message.

In earlier court testimony, Mr. Logan said that he and a colleague in the Georgia office had started investigating child pornography cases because "we had the opportunity and the equipment," particularly the RoundUp program, and that he had been involved in at least 20 other child pornography investigations. It was standard practice, he said, to scrutinize computers within a designated geographic area, without any way to limit searches to those owned by military or government personnel.

A spokeswoman for the investigative service declined to talk about the scope of the work at the Georgia location by officers like Mr. Logan, or whether the service has undertaken similar wide searches for child pornography offenders in other states with a significant Navy presence, like Florida, Virginia or California.

"We're not going to talk about it, because the case is still pending," said MaryAnn Cummings, communications director for N.C.I.S.

It is unclear how often computer investigations by the naval investigative service or other military agencies have yielded evidence of child pornography or other crimes that was handed to civilian authorities.

In one case with similarities to that of Mr. Dreyer, an appeals court reached a different conclusion. In an undercover investigation in 2008 on a Yahoo chatroom, an N.C.I.S. agent located in Bremerton, Wash., spoke with a man in Louisville, Ky., who sent pictures of naked children.

Law enforcement authorities obtained a search warrant, and the man, James L. Holloway, was sentenced to eight years in federal prison. In a decision on July 30, 2013, the United States Court of Appeals for the Sixth Circuit turned down Mr. Holloway's request to suppress evidence based on the Posse Comitatus Act, arguing that the military's involvement had been minimal.