WASHINGTON (AP) — The director of national intelligence on Saturday declassified more documents that outline how the National Security Agency was first authorized to start collecting bulk phone and Internet records in the hunt for al-Qaida terrorists and how a court eventually gained oversight of the program.

The declassification came after the Justice Department complied with a federal court order to release its previous legal arguments for keeping the programs secret.

Director of National Intelligence James Clapper explained in a statement Saturday that President George W. Bush first authorized the spying in October 2001, as part of the Terrorist Surveillance Program, just after the Sept. 11 attacks. Bush disclosed the program in 2005. The Terrorist Surveillance Program — which had to be extended every 30-60 days by presidential order — eventually was replaced by the Foreign Intelligence Surveillance Act, a law that requires a secret court to approve the bulk collection.

Clapper also released federal court documents from successive intelligence directors arguing to keep the programs secret, after a California judge this fall ordered the administration to declassify whatever details already had been revealed as part of the White House's campaign to justify the NSA surveillance. Former agency contractor Edward Snowden first made the surveillance programs public in leaks to the media.

A senior intelligence official Saturday confirmed that the documents were released as part of two long-running class-actions cases against the NSA in California. The official said that at the judge's direction the administration reviewed prior declarations in order to relate information that is no longer classified and determined what could be released. The official spoke on condition of anonymity because he was not allowed to describe the court case by name.

President Barack Obama hinted Friday that he would consider some changes to NSA's bulk collection of Americans' phone records to address the public's concern about privacy. His comments came in a week in which a federal judge declared the NSA's collection program is probably unconstitutional, and a presidential advisory panel suggested 46 changes to NSA operations.

Story continues

The judge said there was little evidence any terror plot had been thwarted by the program, known as Section 215 of the USA Patriot Act. The advisory panel recommended continuing the program but requiring a court order for each NSA search of the phone records database, and keeping that database in the hands of a third party — not the government. Obama said he would announce his decisions in January.

"There has never been a comprehensive government release ... that wove the whole story together — the timeline of authorizing the programs and the gradual transition to (court) oversight," said Mark Rumold, staff attorney at the Electronic Frontier Foundation, a civil liberties group suing the NSA to reveal more about the bulk records programs. "Everybody knew that happened, but this is the first time I've seen the government confirm those twin aspects."

That unexpected windfall of disclosures early Saturday came along with the release of documents outlining why releasing the information would hurt national security. The U.S. District Court in the Northern District of California in the fall had ordered the Obama administration to make public the documents, known as state secrets declarations.

The Justice Department issued the declarations late Friday in the two class-action cases: Shubert v. Bush, now known as Shubert v. Obama, on behalf of Verizon customers; and Jewel v. NSA, on behalf of AT&T customers.

Calls to the Justice Department were not answered.

"In September, the federal court in the Northern District of California ... ordered the government to go back through all the secret ex-parte declarations and declassify and release as much as they could, in light of the Snowden revelations and government confirmations," Rumold said. "So what was released late last night was in response to that court order."

In one such legal argument, former National Intelligence Director Dennis Blair in 2009 told the court that revealing information — including how information was collected, whether specific individuals were being spied upon and what the programs had revealed about al-Qaida — could damage the hunt for terrorists.

"To do so would obviously disclose to our adversaries that we know of their plans and how we may be obtaining information," Blair said. Much of his 27-page response is redacted.

___

Follow Dozier on Twitter at: http://twitter.com/KimberlyDozier

___

Online:

http://icontherecord.tumblr.com/