Facebook does not have legal standing to challenge search warrants on behalf of its users, a New York appeals court has ruled in what was the biggest batch of warrants the social-media site said it ever received at one time.

Facebook was served with 381 warrants in 2013 from Manhattan District Attorney Cyrus Vance Jr. The warrants sought photos, private messages, and other information as part of a wide-ranging disability fraud investigation. As many as 134 people have been accused of disability fraud as part of the ongoing probe.

Facebook objected to handing over the data and challenged it. The site was even threatened with contempt of court over the fight, so it reluctantly coughed up the data. Facebook was allowed to continue the challenge on appeal in a failed bid to set legal precedent for its users.

The company said in a statement it was exploring its legal options:

"We continue to believe that overly broad search warrants—granting the government the ability to keep hundreds of people's account information indefinitely—are unconstitutional and raise important concerns about the privacy of people's online information."

The appeals court realized that New York prosecutors were given a treasure trove of data.

"Our holding today does not mean that we do not appreciate Facebook’s concerns about the scope of the bulk warrants issued here," the New York State Supreme Court, Appellate Division ruled Tuesday. "Facebook users share more intimate personal information through their Facebook accounts than may be revealed through rummaging about one’s home."

Facebook argued that the "vast scope of the government's search and seizure here would be unthinkable in the physical world." But in the end, the court said that judges determine whether warrants are valid before issuing them. Facebook users, or anybody targeted by a search warrant, can continue to challenge them before a trial.

New York authorities said the warrants led to the indictments of firefighters, police officers, and civil servants on disability fraud charges. The Facebook data, which included user photos and videos, showed employees who claimed they were disabled performing a variety of activities, including fishing, martial arts, and even jet ski riding.

"In many cases, evidence on their Facebook accounts directly contradicted the lies the defendants told to the Social Security Administration," Vance spokeswoman Joan Vollero said in a statement. "As part of their sentences – which include probation, community service, and, in some instances, jail time – the defendants have also been sentenced to pay back more than $24.7 million in forfeiture and restitution that they stole from U.S. taxpayers."