WASHINGTON — The head of the Senate Intelligence Committee accused the CIA Tuesday of criminal activity in improperly searching a computer network set up for lawmakers investigating allegations that the agency used torture in terror investigations during the Bush administration.

Democrat Dianne Feinstein, in an extraordinary speech on the Senate floor, publicly aired an intense but formerly quiet dispute between Congress and the spy agency. She said the matter has been referred to the Justice Department for further investigation.

Both Feinstein and the CIA have accused each other's staffs of improper behavior. She said she had "grave concerns that the CIA's search may well have violated the separation of powers principles embodied in the United States Constitution."

CIA Director John Brennan, asked about Feinstein's accusations, said the agency was not trying to stop the committee's report and that it had not been spying on the panel or the Senate. He said the appropriate authorities would look at the matter further and "I defer to them to determine whether or not there was any violation of law or principle."

Brennan informed Feinstein of the computer search in January, according to the senator. He denied that the CIA "hacked" into the computer network in remarks on Tuesday but did not address the question of a search.

The CIA provided computers to congressional staffers in a secure room in northern Virginia in 2009 so the panel could review millions of pages of top secret documents in the course of its investigation into the CIA's detentions and interrogations during the Bush administration. At issue now is whether the CIA violated an agreement made with the Senate Intelligence Committee about monitoring the panel's use of CIA computers.

Feinstein said the Senate staff members had an electronic search tool to deal with 6.2 million pages of documents and the ability to make copies on their computers. She said the arrangement suffered a blow when CIA personnel electronically removed the committee's access to documents that had already been provided to the panel.

She said about 870 documents were removed in February 2010, and an additional 50 were withdrawn without the knowledge of the committee.

Feinstein said she has asked the agency for an apology but the CIA has been silent.

The dispute comes as the Obama administration is trying to regain public trust after classified details about widespread surveillance of Americans were disclosed by former National Security Agency systems analyst Edward Snowden last summer. The dispute does not involve the NSA spying on Americans, but it does show a fractious relationship between the U.S. spy agencies and the Congress charged with overseeing them.

Feinstein, as head of the Intelligence panel, has defended the NSA against criticism of its practices, making her comments about the CIA dispute highly unusual. Senators said the stakes demanded it.

"If we do not stand up for the protection of the separation of powers and our ability to do oversight, especially when conduct has happened that is all likelihood criminal conduct on the part of a government agency, then what do we stand for?" asked Sen. Patrick Leahy, D-Vt., chairman of the Judiciary Committee.

Republican Sen. Lindsey Graham of South Carolina also reflected congressional anger.

"Heads should roll, people should go to jail if it's true," Graham said. "If it is, the legislative branch should declare war on the CIA."

Saying she wanted to set the record straight amid various published reports and rampant speculation, Feinstein said the CIA searched the computer network in January and she had pressed Brennan about the agency's actions and the legal basis for its search. She said she had not received any answers despite letters sent on Jan. 17 and Jan. 23.

Feinstein said the CIA's inspector general, David Buckley, has referred the matter to the Justice Department "given the possibility of a criminal violation by CIA personnel."

In further evidence of the escalating fight, Feinstein said that after the inspector general's referral, the acting counsel of the CIA filed a criminal report with the Justice Department regarding the committee staff's actions.

Feinstein defended the staff as professionals with appropriate security clearances.

"I view the acting counsel general's referral as a potential effort to intimidate this staff, and I am not taking it lightly," she said.

Feinstein did not name the CIA lawyer, but two congressional officials identified the official as Robert Eatinger, who was involved in legal decisions involving agency interrogations during the Bush administration.

The officials commented only on condition of anonymity, citing the classified nature of the internal investigations.

Feinstein said the lawyer was the chief lawyer for the CIA's Detention and Interrogation program from mid-2004 until it was terminated by an executive order signed by President Barack Obama in January 2009.

Feinstein said the lawyer "was mentioned by name more than 1,600 times in our study. And now this individual is sending a crimes report to the Department of Justice on the actions of congressional staff." She added that the Senate report "details how CIA officers including the acting general counsel himself provided inaccurate information to the Department of Justice about the program."

Sen. Saxby Chambliss of Georgia, the top Republican on the Intelligence Committee, said he disagreed with Feinstein on the dispute with the CIA, without fully specifying. He called for a study "on what happened so people can find out what the facts are."

"Right now we don't know what the facts are," Chambliss told reporters. "We're going to continue to deal with this internally."

Brennan, who was questioned at an appearance on another subject, said "We are not in any way, shape or form trying to thwart this report."

"I am confident that the authorities will deal with this appropriately," he said. "I would just encourage some members of the Senate to take their time, to make sure they don't overstate what they claim and what they apparently believe to be the truth."

Democrats on the Senate Intelligence Committee completed their 6,300-page interrogation report last year and are revising it with CIA comments. Feinstein said she would ask the White House to declassify its 300-plus-page executive summary, and its conclusions.

When the report was first approved by Democrats on the committee in December 2012, Feinstein said her staffers came to the conclusion that the detention and interrogation program yielded little or no significant intelligence.