The White House filed papers late Friday to stop a federal judge from deciding whether warrantless surveillance operations are legal or not.

The government said that, despite leaks by former National Security Agency contractor Edward Snowden, full disclosure of the surveillance data would put government secrets at risk. Divulging these secrets in a court would cause “extremely grave damage to the national security of the United States,” wrote James Clapper Jr., the director of national intelligence, in the filing.

In the filing for two long-running cases in the Northern District of California, the attorneys for the White House acknowledged that the NSA started collecting data on Americans’ emails and phone calls in 2001 without getting permission from a court for each specific request. The government argued that disclosure of these secrets would put the country at risk if they were publicized.

The government can use its state secrets privilege to block information from being used in a court, and the Justice Department has asked the federal judge, Jeffrey S. White of the Northern District of California, to dismiss the case without ruling on whether the programs violated the First or Fourth Amendments of the Constitution. White had earlier ordered the government to evaluate how the disclosures by Snowden had affected its earlier assertions of state secrets.

The plaintiffs, which include the Electronic Frontier Foundation, have until late January to file a response. Cindy Cohn, the legal director for the Electronic Frontier Foundation, told the New York times that the government’s assertion was “very troubling.” The comment by Clapper contrasts with the findings of President Obama’s advisory committee on signals intelligence, which said in a disclosure made public last week that the collection of bulk telephone data was of little value.

Clapper argued that the program was vital to stopping terrorist threats from Al Qaeda and other groups.

“Disclosing or confirming further details about these activities could seriously undermine an important tool — metadata collection and analysis — for tracking possible terrorist plots,” he wrote, and could reveal methodology, thus “helping foreign adversaries evade detection.”

The California lawsuit dates back to 2006, after the New York Times revealed that the Bush administration had authorized warrantless wiretaps.