The Justice Department recently questioned military defense attorneys at Guantanamo Bay about whether photographs of CIA personnel, including covert officers, were unlawfully provided to detainees charged with organizing the Sept. 11, 2001, attacks, according to sources familiar with the investigation.

Investigators are looking into allegations that laws protecting classified information were breached when three lawyers showed their clients the photographs, the sources said. The lawyers were apparently attempting to identify CIA officers and contractors involved in the agency's interrogation of al-Qaeda suspects in facilities outside the United States, where the agency employed harsh techniques.

If detainees at the U.S. military prison in Cuba are tried, either in federal court or by a military commission, defense lawyers are expected to attempt to call CIA personnel to testify.

The photos were taken by researchers hired by the John Adams Project, a joint effort of the American Civil Liberties Union and the National Association of Criminal Defense Lawyers, to support military counsel at Guantanamo Bay, according to the sources, who spoke on the condition of anonymity because of the sensitive nature of the inquiry. It was unclear whether the Justice Department is also examining those organizations.

Both groups have long said that they will zealously investigate the CIA's interrogation program at "black sites" worldwide as part of the defense of their clients. But government investigators are now looking into whether the defense team went too far by allegedly showing the detainees the photos of CIA officers, in some cases surreptitiously taken outside their homes.

If proved, the allegations would highlight how aggressively both military lawyers and their allies in the human rights community are moving to shed light on the CIA's interrogation practices and defend their clients. Defense attorneys, however, described the investigation as an attempt by the government to intimidate them into not exposing what happened to their clients.

When contacted about the investigation, the ACLU declined to discuss specifics.

"We are confident that no laws or regulations have been broken as we investigated the circumstances of the torture of our clients and as we have vigorously defended our clients' interests," said Anthony D. Romero, the group's executive director. "Rather than investigate the CIA officials who undertook the torture, they are now investigating the military lawyers who have courageously stepped up to defend these clients in these sham proceedings."

It is unclear whether the military lawyers under investigation identified the CIA personnel in the photographs to the al-Qaeda suspects or simply asked the detainees whether they had ever seen them. It is also unclear whether the inquiry involves violations of federal statutes prohibiting the identification of covert CIA officers or violations of military commission rules governing the disclosure of classified information, including to the defendants.

The investigation is being overseen by John Dion, head of the Justice Department's counter-espionage section, who has worked on many high-profile national security cases, including the prosecution of Aldrich H. Ames, the CIA mole who spied for the Soviet Union. The CIA reports security breaches to Dion's office. The Justice Department and the CIA declined to comment.

Air Force Col. Peter R. Masciola, chief military defense counsel at Guantanamo Bay, and his deputy, Michael J. Berrigan, also declined to comment.

The Washington Post could not determine how many and which CIA personnel were photographed, which photographs were shown to detainees, or when.

Romero said he does not know what laws the government thinks the military lawyers may have broken.

"That is the most vexing part of it," he said. "Usually when you're read your Miranda rights or visited by the Justice Department or the FBI, you are given some indication as to what laws are at stake."

The National Association of Criminal Defense Lawyers also declined to address the specifics of the inquiry but questioned its timing.

It is "customary in our experience that any kind of investigation like these are conducted after legal proceedings are finished in the case so as not to interfere with the defense function, not to interfere with the rights of defendants, not to give the appearance that the government is looking to chill the defense function," said Joshua L. Dratel, counsel for the John Adams Project and a former board member of the NACDL, who spoke on behalf of the group.

He added: "The lawyers have a duty to find out what happened to their clients, and to the extent that the government and certain agencies are resistant to that to protect themselves and to insulate themselves from accountability, there is a tension there, and to the extent that this investigation is part of that tension, it's most unfortunate. But the lawyers will not shirk their duty."

A wide variety of groups, including European investigators, human rights groups and news organizations, have compiled lists of people thought to have been involved in the CIA's program, including CIA station chiefs, agency interrogators and medical personnel who accompanied detainees on planes as they were moved from one secret location to another.

"It's a normal part of human rights research projects, and certainly in defense work, to compile lists of individuals who interacted with clients," Romero said.

Tracking international CIA-chartered flights, researchers have identified hotels in Europe where CIA personnel or contractors stayed. In some cases, through hotel phone records, they have been able to identify agency employees who jeopardized their cover by dialing numbers in the United States. Working from these lists, some of which include up to 45 names, researchers photographed agency workers and obtained other photos from public records, the sources said.

The government has largely cut off the airing of details about the CIA's interrogation program during proceedings at Guantanamo Bay, although many have been revealed in government documents.

At the courthouse at the prison, a court security officer, who is thought be in contact with CIA officials, can cut off the audio feed to the public gallery if there is any possibility of lawyers or defendants discussing CIA detention. At a hearing in July, the audio feed was cut when a lawyer for Ramzi Binalshibh, one of the alleged Sept. 11 conspirators, mentioned sleep deprivation, one of the "enhanced interrogation techniques" used at the CIA's black sites.