An appeals court has ruled that Google will have to deal with an investigation into its business practices by Mississippi Attorney General Jim Hood. The court also noted the search company can still challenge the investigation at a later time.

It's a reversal of a big win by Google last year when a federal judge halted the Mississippi investigation, which sought information about how Google deals with links related to counterfeit goods, illegal drug sales, copyright violations, and other matters. Google sued to stop the investigation while litigation was underway, saying that Hood's goal was to "punish" Google while he pursued his goal of a "pre-filtered Internet"—a power denied him by both Congress and the Constitution, Google lawyers argued.

Hood's investigation had been egged on by lobbyists from the Motion Picture Association of America, and in some cases demand letters that came from Hood's office were actually written by MPAA lawyers.

Today, the US Court of Appeals for the 5th Circuit overturned Google's win on procedural grounds. In a 23-page opinion (PDF), a three-judge panel said that the district court judge had been too quick to grant relief to Google.

"This injunction covers a fuzzily defined range of enforcement actions that do not appear imminent," the appeals judges held. "We cannot on the present record predict what conduct Hood might one day try to prosecute under Mississippi law."

Hood's subpoenas were a "pre-litigation investigative tool" seeking information about a wide array of topics, including copyright infringement, illegal prescription drug sales, human trafficking, false IDs, and credit card theft.

The opinion notes that Google doesn't have to comply with the subpoena. The company could refuse to provide information, which could lead Hood to enforce it through state courts. Google's objections could be raised in that venue, the appeals court noted.

Although it's a setback for Google, the opinion clearly shows the appeals court sees how broad Hood's investigation was. The opinion says some of the subpoena's requests "would require massive document production." Many of the document requests "lack temporal limitations."

The judges also took note of how far Google has already gone to appease Hood's demands, including voluntarily sharing about 100,000 pages of documents. The search company also made changes in requests to Hood's investigation, such as creating a "trusted flag" mechanism that Hood's office could use to get Google to promptly review videos.

"After being trained on that tool, Hood's office flagged seven videos, six of which Google quickly took down," the opinion states. "When asked by the district court, Hood's counsel could not identify any investigatory efforts related to the videos his office flagged."

Despite that, the opinion shows that the Mississippi official's demands for changes to Internet search remain vast. Hood wants Google to promote sites that are "authorized to provide content" and mark them as such, and he asks the search giant to remove sites "substantially dedicated to intellectual property infringement," a demand the entertainment industry has been making for many years. Hood also wants Google to stop indexing sites that have been the subject of "multiple notices of infringement" and "dramatically demote 'rogue' infringement sites in search results."

"We're reviewing the implications of the Court's decision, which focused on whether our claim was premature rather than on the merits of the case," a Google spokesperson told Ars via e-mail.

"We’ll have to evaluate it," Hood said at a press conference held today in Mississippi. "We’ll have to go see what they’re doing online now, and see what action we take next."

Hood also criticized Google, saying the company has been less helpful than others when it comes to helping state officials apprehend or cut off off intellectual property thieves and other types of criminals who operate online.

"You know that's pretty arrogant for a company to just go out and sue a state prematurely," he said. "I'm glad the 5th Circuit, with the Chief Justice sitting on the panel, told them so."