When the C.I.A.’s inspector general challenged these “enhanced interrogation” methods, the agency’s Office of Medical Services was brought in to determine, in consultation with the Justice Department, whether the techniques inflicted severe mental pain or suffering, the legal definition of torture. Once again, doctors played a critical role, providing professional opinions that no severe pain or suffering was being inflicted.

According to Justice Department memos released last year, the medical service opined that sleep deprivation up to 180 hours didn’t qualify as torture. It determined that confinement in a dark, small space for 18 hours a day was acceptable. It said detainees could be exposed to cold air or hosed down with cold water for up to two-thirds of the time it takes for hypothermia to set in. And it advised that placing a detainee in handcuffs attached by a chain to a ceiling, then forcing him to stand with his feet shackled to a bolt in the floor, “does not result in significant pain for the subject.”

The service did allow that waterboarding could be dangerous, and that the experience of feeling unable to breathe is extremely frightening. But it noted that the C.I.A. had limited its use to 12 applications over two sessions within 24 hours, and to five days in any 30-day period. As a result, the lawyers noted the office’s “professional judgment that the use of the waterboard on a healthy individual subject to these limitations would be ‘medically acceptable.’”

The medical basis for these opinions was nonexistent. The Office of Medical Services cited no studies of individuals who had been subjected to these techniques. Its sources included a wilderness medical manual, the National Institute of Mental Health Web site and guidelines from the World Health Organization.

The only medical source cited by the service was a book by Dr. James Horne, a sleep expert at Loughborough University in Britain; when Dr. Horne learned that his book had been used as a reference, he said the C.I.A. had distorted his findings and misrepresented his research, and that its conclusions on sleep deprivation were nonsense.