In the evening, while he was held captive at a secret CIA black site in Thailand, the high-value detainee Zayn al-Ibidin Muhammed Husayn said his interrogators would torture him by confining him to a large, six-foot-tall black wooden box in "extremely uncomfortably positions." Other times, they would force him to spend hours in a small "dog box."

The detainee, better known by his surname, Abu Zubaydah, said he was deprived of "adequate air" and food in the boxes while an "extreme noise machine nearby" tormented him.

This was the start of "my most painful and cruel period of torture," Abu Zubaydah said. The "pain in the small box was unbearable. I was hunched over in a contorted way and my back and knees were in excruciating pain. I began slamming my body and shackled arms against the inside and screaming for help and tried to break the door. The wound in my stomach and leg opened up and I started bleeding, yet I didn't care. I would do anything to stretch my leg and back for one minute."

Abu Zubaydah, 45, a Saudi national who was the CIA's first captive following the 9/11 attacks, served as the guinea pig for what the CIA euphemistically referred to as its "enhanced interrogation" program. The details about Abu Zubaydah's treatment were revealed in a sworn, eight-page declaration [PDF at the end of this story] he provided to his attorney in 2009 that was filed under seal in US District Court in Washington, DC seven years ago in his habeas corpus case in which his attorneys have argued for his release.

That declaration was unsealed one week ago, prepared for public release in response to a motion filed earlier this year by investigative journalist Raymond Bonner, who convinced the federal judge presiding over Abu Zubaydah's case to unseal dozens of court filings that have been shrouded in secrecy since 2008.

Abu Zubaydah. (Photo via Getty Images)

The judge who previously oversaw the case, Richard Roberts, failed to rule on nearly every motion Abu Zubaydah's attorneys have filed over the past seven years. He abruptly retired from the bench as chief judge of the US District Court for the District of Columbia on March 16, the same day a woman filed a lawsuit accusing him of sexually assaulting her more than three decades ago when she was 16 years old.

The partially redacted declaration was attached as an exhibit to a 21-page motion his attorneys filed on September 21, 2009 asking the court to impose sanctions against the government for destroying "material evidence" — nearly 100 interrogation videotapes, at least one of which showed Abu Zubaydah being waterboarded.

The destruction of the videotapes was the catalyst behind the Senate Intelligence Committee's decision in 2009 to launch an investigation into the efficacy of the CIA's torture program. In December 2014, the committee released a 500-page declassified executive summary of its landmark 6,600-page report, which concluded that the torture of Abu Zubaydah and other detainees in the custody of the CIA failed to produce unique and valuable intelligence — and that the torture was far more brutal than the CIA had let on. The CIA disputed some of the Intelligence Committee's findings and insisted that a majority of the intelligence the agency gleaned about Al Qaeda and other accused terrorists captured by the US military was based on information Abu Zubaydah and Khalid Sheikh Mohammed, the accused mastermind of the 9/11 attacks, provided to their interrogators.

He said he did provide 'basic information' about al-Qaeda, but that it was 'information anyone in Afghanistan could know.'

The unsealing of the court filing along with Abu Zubaydah's declaration occurred about a month before the high-value detainee is expected to have a hearing before a so-called period review board, whose job is to assess whether "continued law of war detention is necessary to protect against a continuing significant threat to the security of the United States," VICE News has learned from military sources.

Abu Zubaydah has never been charged with war crimes. After his capture, numerous senior Bush administration officials erroneously claimed the detainee helped plan the 9/11 attacks and was the "No. 3" person in al-Qaeda. In October 2009, the Obama administration quietly admitted in a court filing that its understanding of Abu Zubaydah's alleged role in al-Qaeda's activities "has evolved with further investigation" and that it no longer stands behind behind the Bush administration's assertions.

While not officially a member of al-Qaeda — he never swore allegiance to Osama bin Laden — Abu Zubaydah served as a facilitator for trainees who went on to engage in al-Qaeda–funded attacks; as such, Abu Zubaydah's name routinely popped up as someone who may have played a role in operational planning.

He first became eligible for a review board hearing, formally referred to as periodic review boards, two years ago. His appearance before the panel, composed of senior officials from the departments of Defense, Homeland Security, Justice, and State; the Joint Chiefs of Staff; and the Office of the Director of National Intelligence, is expected be held at Guantanamo next month. It will mark the first time he has been seen in public since his capture on March 28, 2002.

It's a significant development, and especially noteworthy given that Abu Zubaydah was never supposed to see the light of day. Indeed, in the Senate Intelligence Committee's torture report, CIA interrogators asked in a cable for "reasonable assurances" that he would "remain in isolation and incommunicado for the remainder of his life" if he did not die during his interrogation.

Much of what Abu Zubaydah described in his declaration about his treatment has been disclosed in the Senate Intelligence Committee's torture report and in his own words in newly declassified transcripts of military hearings held for CIA captives months after they were transferred to Guantanamo from CIA black sites in September 2006. The release of Abu Zubaydah's declaration is now another addition to the detainee's first-person account of his torture. It contains new details about how he was interrogated and what he told his interrogators. Because of the conditions of his confinement, however, his recounting of dates may not be reliable.

Abu Zubaydah, whose left eye was removed during his detention, apparently due to a "preexisting condition," according to a US counterterrorism official, is the only CIA detainee who was subjected to all 10 enhanced interrogation techniques that the Department of Justice sanctioned in a legal opinion commonly referred to as the "torture memo."

"All of the techniques were applied to him. In fact, no one else endured all the techniques," said Joseph Margulies, one of Abu Zubaydah"s attorneys, in past interviews.

The most controversial of the 10, the waterboard, was administered over the course of a week, Abu Zubaydah said, "as best as I can remember." He said he was strapped to the waterboard by guards with "black costumes, masks, and black goggles."

"My mouth and nose and eyes were covered by a cloth," he said. "The board — and my body — were placed horizontally. My head was immobilized by a board. Someone poured over the cloth, which entered my mouth and nose. I could hear one water bottle empty out by the gurgling noise it made; I hoped that would end the process, then I heard another bottle start to pour. Water would enter into my lungs. It felt like my whole body was filled with water; even my eyes felt like they were drowning."

Abu Zubaydah went on to say that he started to experience "the panicked sensation of death" and his body "convulsed in terror and resistance."

"I thought, 'I will die. I will die.' I lost control of my functions and urinated on myself," he said.

The Senate Intelligence Committee's torture report revealed that at one point during his waterboarding session, Abu Zubaydah became "completely unresponsive, with bubbles rising through his open, full mouth." He had to be resuscitated.

Donald Trump, the presumptive Republican presidential nominee, said during a campaign stop last week, "I like waterboarding a lot," and has vowed that he would bring back torture if he is elected president.

In an exclusive interview with VICE News in December 2014, Dr. James Mitchell, a retired Air Force psychologist and one of the architects of the CIA's interrogation program, said he personally waterboarded Abu Zubaydah and explained why the technique was used.

"The whole point of the waterboard was to induce fear and panic," Mitchell said. "We didn't think [detainees were] going to provide actionable intelligence in a state of fear and panic. You have to start the session with the waterboarding, but the questioning happens the next time you come in the room. It's like any sort of thing you fear: The closer you get to it the next time, the more you struggle to get out of it and find an escape. So the moment [a detainee] was most susceptible to beginning to provide information was just before the next waterboarding session. Not in the original one."

Abu Zubaydah said in his declaration that after he was waterboarded, someone — the person's name was redacted — would ask, "Are you ready to talk?" But he said he had nothing to tell his interrogators other than that they were "wrong about me." He said he was told that "nobody in Washington believes you." Then he was waterboarded some more.

In documents released last month in response to separate Freedom of Information Act (FOIA) lawsuits filed by VICE News and the ACLU, the CIA released a memo from the agency's chief of medical services who said that Abu Zubaydah already started to cooperate with his interrogators prior to being subjected to waterboarding. The memo said waterboarding Abu Zubaydah did not produce "time-perishable information which otherwise would have been unavailable" and that a "psychologist/interrogator later said that waterboard use had established that AZ had no further information on imminent threats — a creative but circular justification," the medical officer wrote, referring to Abu Zubaydah by his initials.

In his declaration, Abu Zubaydah said he also endured constant sleep deprivation, was shackled to a chair naked in freezing temperatures for two to three weeks, was "bombarded with high-decibel noise," and deprived of solid food.

When he was subjected to the technique known as "walling," in which a detainee is slammed into a "flexible" wall in order to "shock" or "surprise" the captive, Abu Zubaydah said his interrogators repeatedly shouted questions at him, which the government redacted. A source knowledgeable about the questions interrogators asked detainees told VICE News that the questions were: Who are the operatives in the US? When is the next attack? Who is conducting the attack?

"Over and over I told them, 'I don't know! I have nothing to tell you! I don't know al-Qaeda or what they are doing!'" he said, noting that he did provide "basic information" about al-Qaeda but that it was "information that anyone who spent time in Afghanistan could know."

He said his first experience with torture while in US custody took place after the FBI started interrogating him about his links to Al Qaeda. Following his recovery from gunshot wounds he sustained after he was captured in Faisalabad, Pakistan on March 28, 2002, during a raid on his safe house jointly conducted by the CIA, FBI, Pakistani police, and the country's Inter-Services Intelligence (ISI), Abu Zubaydah said he was subjected to "constant sleep deprivation," was shackled to a chair "naked in freezing temperatures for about 2-3 weeks," "bombarded with high-decibel noise," and deprived of solid food. He said he was repeatedly accused by the FBI interrogators of being a top al-Qaeda operative, which he denied. He claimed his denials would have been captured on the videotapes of his interrogations that were eventually destroyed. Abu Zubdaydah said that after his FBI interrogators left the black site in Thailand he spent a month in isolation "with no contact with interrogators."

Then the CIA took over.

Before the start of his "most painful and cruel period of torture" by the CIA, which commenced with the confinement in the large box, Abu Zubaydah said guards had entered his cell with a man who Abu Zubaydah said he later learned worked for the CIA. They shouted obscenities at him. He said one of the interrogators slammed him against the concrete wall, "hitting my head repeatedly."

"[The interrogator] said something like, 'Are you ready to talk? Now we are going to tell you how real interrogation is done!'"

After being subjected to marathon interrogation and torture sessions, Abu Zubaydah said he asked his interrogators, "Tell me what you want me to say, I will say!" Sometimes, he acknowledged, he "just said things that were false and that I had no basis to know or believe, simply to get relief from the pain."

Eventually, Abu Zubaydah said his interrogators came to believe that he was telling the truth about his relative innocence, that his case "was a mistake," and that he did not possess intelligence about al-Qaeda's terrorist plots against the US, a conclusion that the Senate Intelligence Committee's report makes clear as well.

He said his interrogators told him that Khalid Sheikh Mohammed and suspected planner of the USS Cole bombing Abdel Rahim al Nashiri were asked about him during their interrogations, and both said it was "absurd" to conclude that Abu Zubaydah was a member of al-Qaeda. They were, supposedly, "surprised the Americans suggested it."

Sometime in 2005, Abu Zubaydah said he was visited by an interrogator [believed to be Mitchell] and the two "got into a political discussion about my beliefs and my desire for a Palestinian homeland, my opposition to violence against civilians, and that I had no interest in hurting Americans or fighting against them. He said he understood this."

Abu Zubaydah's own diaries, government translations of which I obtained three years ago, contradict his assertions. In one volume he wrote, "I wished to see America's fall and destruction, and the destruction of the State of Israel, and I wished to torture and kill them myself with a knife."

Abu Zubaydah said his interrogator admitted during their conversation "that the US was wrong about me."

"He said he had no problem doing what he did — i.e., torture — to Khaled Sheik Mohammed, but he was very sorry about what had been done to me, because I was not the person they once thought I was. At one point during this conversation, [the man] became "emotional and unable to speak; he removed his glasses and wiped his eyes," Abu Zubaydah said.

Abu Zubaydah claimed that during another instance in 2005, "at a location I do not know [believed to be a black site in Lithuania], I was visited by a high level official in the US government."

"I was told that this person was the head of the [CIA] program I was in," Abu Zubaydah said. "I met with him on two occasions to discuss my conditions. During the first conversation, he said that what happened to me was bad, and took personal responsibility for it; even saying it was a mistake. He said he wished to put these events behind us, and make things better for me now and in the future. He agreed to return my diaries, give me exercise equipment, improve the food, and cease the body cavity searches."

A CIA spokesperson was unavailable for comment. Still, it's unlikely a "high-level US government official" visited Abu Zubaydah. CIA contractors have been known to dupe detainees into believing they work for the US government in a senior capacity.

How the public release of Abu Zubaydah's declaration will factor into his ongoing habeas corpus case remains unclear. But Brent Mickum, one of Abu Zubaydah's attorneys, told VICE News that what's important about it is that it provides his client an opportunity to defend himself, which he has not been able to do in the 14 years he's been detained by the US.

"What we needed to do was to be able to tell his story," Mickum said. "For years, the government has tried to muzzle our client and muzzle us. We were incapable of defending our client in public with his own words. We have not been able to provide his side of the story because everything has been classified. With the release of this declaration, Abu Zubaydah can finally speak and defend himself."