WASHINGTON — Shortly after 9/11, the CIA considered using a drug it thought might work like a truth serum and force terror suspects to give up information about potential attacks.

After months of research, the agency decided that a drug called Versed, a sedative often prescribed to reduce anxiety, was "possibly worth a try." But in the end, the CIA decided not to ask government lawyers to approve its use.

The existence of the drug research program — dubbed "Project Medication" — is disclosed in a once-classified report that was provided to the American Civil Liberties Union under a judge's order and was released by the organization Tuesday.

The 90-page CIA report, which was provided in advance to The Associated Press, is a window into the internal struggle that medical personnel working in the agency's detention and harsh interrogation program faced in reconciling their professional ethics with the chance to save lives by preventing future attacks.

"This document tells an essential part of the story of how it was that the CIA came to torture prisoners against the law and helps prevent it from happening again," said ACLU attorney Dror Ladin.

Between 2002 and 2007, CIA doctors, psychologists, physician assistants and nurses were directly involved in the interrogation program, the report said. They evaluated, monitored and cared for 97 detainees in 10 secret CIA facilities abroad and accompanied detainees on more than 100 flights.

The CIA ultimately decided against asking the Justice Department to approve drug-assisted interrogations, sparing CIA doctors "some significant ethical concerns," the report said. It had taken months for the Justice Department to sign off on brutal interrogation tactics, including sleep deprivation, confinement in small spaces and the simulated drowning technique known as waterboarding. The CIA's counterterrorism team "did not want to raise another issue with the Department of Justice," the report said.

Before settling on Versed, the report said researchers studied records of old Soviet drug experiments as well as the CIA's discredited MK-Ultra program from the 1950s and 1960s that involved human experimentation with LSD and other mind-altering drugs on unwitting individuals as part of a long search for some form of truth serum. These experiments were widely criticized and, even today, some experts doubt an effective substance exists.

"But decades later, the agency was considering experimenting on humans again to test pseudo-scientific theories of learned helplessness on its prisoners," Ladin said.

Versed is a brand name for the sedative midazolam, used since the late 1970s and today sold commonly as a generic. It causes drowsiness and relieves anxiety and agitation. It also can temporarily impair memory, and often is used for minor surgery or medical procedures such as colonoscopies that require sedation but not full-blown anesthesia. It's in a class of anti-anxiety medications known as benzodiazepines that work by affecting a brain chemical that calms the activity of nerve cells.

"Versed was considered possibly worth a trial if unequivocal legal sanction first were obtained," the report said. "There were at least two legal obstacles: a prohibition against medical experimentation on prisoners and a ban on interrogational use of 'mind-altering drugs' or those which 'profoundly altered the senses.'"

Those questions became moot after the CIA decided against asking the Justice Department to give it a green light. "At the beginning of 2003, the Office of Medical Services' review, informally termed 'Project Medication' was shelved, never to be reactivated," the report said.

The CIA had no comment on the report's release, but government lawyers emphasized in a court filing in the case early last year that the report, expressly marked "draft," was just one agency officer's impressions of the detention and interrogation program. The document is not the CIA's or the Office of Medical Service's "final official history, or assessment, of the program," the lawyers wrote.

The ACLU spent more than two years in court trying to get the report released. In September 2017, a federal judge in New York ordered the CIA to release it. Government lawyers tried three more times to keep information contained in the report under wraps, but the ACLU received the bulk of the report in August. The government is still fighting to keep portions secret. They are to file briefs in a federal appeals court in New York on Wednesday, arguing that the judge ordered too much released.

While the CIA's harsh interrogation program ended in 2007, the ACLU believes it's important to continue seeking the release of documents about it, especially since President Donald Trump declared during his campaign that he would approve interrogating terror suspects with waterboarding, which is now banned by U.S. law, and a "hell of a lot worse."

CIA Director Gina Haspel, who was involved in supervising a secret CIA detention site in Thailand where detainees were waterboarded, told the Senate during her confirmation hearing that she does "not support use of enhanced interrogation techniques for any purpose."

The report cites many instances where medical personal expressed concern or protected the health of the detainees. Those who were thrown up against walls — a practice called "walling" — had their necks protected from whiplash by rolled towels around their necks, the report said. When one detainee, who had been wounded during capture, was confined to a box, care was taken not to force his legs into a position that "would compromise wound healing." Physician assistants overruled using duct tape over the mouths of detainees during flights because air sickness could lead to vomiting and possible aspiration.

"That doesn't mean that the doctors were sadistic or anything like that," Ladin said. "But it means they were complicit because this pseudo-scientific torture could not have happened without the doctors' participation."

At the same time, the medical office's report said waterboarding was not "intrinsically painful." It said there was "physical discomfort from the occasional associated retching," but that two detainees who endured the most extensive waterboarding sessions complained only "of the pain of the restraining straps."

That contrasts with the Senate's 2014 report on the CIA's interrogation program, which stated that a prisoner known as Abu Zubaydah, a suspected al-Qaida operative who was waterboarded more than 80 times, "cried, begged, pleaded, vomited, and required medical resuscitation after being waterboarded."

Some CIA medical personnel called waterboarding "little more than an amateurish experiment" and others worried that the practice would trigger spasms of the vocal cords, which could, at least temporarily, make it hard to speak or breathe.

At the same time, other medical personnel contended waterboarding actually "provided periodic relief" to a prisoner because it was a break from being forced to stand for long periods of time. The agency medical personnel also said the harsh interrogation program was "reassuringly free of enduring physical or psychological effects."

Dr. Sondra Crosby, who has treated victims of torture, including two who were held at CIA secret sites, disagreed.

"The enduring pain and suffering experienced by the survivors of the CIA program is immense, and includes severe, complex post-traumatic stress disorder, depression, physical ailments, and psychosocial dysfunction," said Crosby, of Boston University's School of Medicine and Public Health. "At least one detainee was tortured to death. Their physical and psychological scars will last a lifetime."