Mohamad Khweis, in a 2010 photo. (Fairfax County Police)

A Virginia man accused of briefly joining the Islamic State was held in a secret Iraqi detention center for three months and was repeatedly interrogated by the FBI, the man’s attorneys said in a new court filing.

During that period, attorneys for Mohamad Khweis said, FBI agents blocked a consular official from connecting the suspected terrorism supporter with his American attorney and put off Kurdish requests that he be taken back to the United States.

Khweis, 27, an American citizen, purportedly joined and then quickly fled the Islamic State early last year. He was captured by Kurdish forces last March and shortly thereafter appeared on Kurdish television decrying his decision to join the terrorist group.

When the FBI began interrogating him in Iraq, according to the court filing, an agent said “he would not stop talking.” According to federal prosecutors, Khweis admitted to taking part in religious training directed by the Islamic State and said he had told the terrorist group that he would be willing to be a suicide bomber.

Khweis’s attorneys argue that their client’s statements were not made voluntarily and should not be allowed at his trial.

“While U.S. law enforcement has an incredible responsibility to protect our national security, it has an equal imperative to protect the rights of its citizens,” Jessica N. Carmichael, one of Khweis’s attorneys, said in a statement.

According to his attorneys, Khweis was exceedingly cooperative because he was desperate to return home. Khweis, who lived in the Alexandria area, said on Kurdish television that after a time with the Islamic State, he realized that he “didn’t really support their ideology” and that life in Mosul was difficult. Growing up in Virginia, he had attended Fairfax County public schools, earned a degree from Northern Virginia Community College, and worked as a bank teller and a bus driver.

“Mr. Khweis attempted to escape Iraq several times,” his attorneys wrote in the court filing. “Initially he was unsuccessful, however, he finally departed one evening and started walking for miles.” He eventually found Kurdish forces­ and was taken to a detention center in Irbil in northern Iraq.

In terrorism cases, the FBI employs a “dirty” team that interrogates suspects for intelligence information that cannot be used in court. Then, a “clean” team comes in, advises the suspect of their rights and collects usable information.

After 11 interrogations in which he was advised that his right to remain silent and a presumption of innocence did not apply in Iraq, Khweis was told that his statements would need to be “consistent” and truthful if he wanted to return to the United States, his attorneys said. Those admonishments, they argue, tainted the subsequent “clean” interviews.

In fact, officials already had begun preparing to take Khweis to the Eastern District of Virginia for prosecution. But, according to the defense filing, even when a consular official arrived to arrange a passport for the trip, she was told to say that “it is for a one-time passport and that a decision has not been made yet whether he will be returned to the U.S.”

Defense attorneys said Khweis was held for three months and questioned over six weeks.

A similar argument regarding the separation of interrogations by “clean” and “dirty” teams was mounted in a New York terrorism case several years ago, but the suspect pleaded guilty before a judge could rule.

Defense attorneys for Khweis also said the FBI put off requests from the State Department to see their client.

“I’m troubled by the implication below that [law enforcement] would play a gate-keeping role for consular access. As you know, this is not appropriate,” a State Department director wrote to Khweis’s consular officer, according to the court filing. The FBI and consular officials discussed the issue by phone, but ultimately, the attorneys said, the matter was not resolved.

When a State Department consular officer tried to reach Khweis and connect him with the American lawyer his family had hired, law enforcement officials said that week “was not good for them.” That was the week his “clean” interrogations with a new FBI team began, according to the filing. Khweis’s attorney John Zwerling was not told where he was until after those interviews.

Meanwhile, according to the documents, Kurdish officials were nervous about detaining Khweis for so long. Under Iraqi law, a prisoner is supposed to see a judge within 24 hours of arrest. Although the Kurds were initially eager to cooperate and share information with U.S. officials, according to the court documents, after several weeks they became frustrated and wanted Khweis either charged in Iraq or taken out of the country.

The lead FBI interrogator warned on April 8 that if the agents did not hurry, Khweis would be brought before a Kurdish judge and “then we are screwed,” according to the defense filing. They needed to “stop the Kurds from having to do what they legally have to do,” he said. The Kurds “don’t want him held without appearing before a judge and getting an attorney when the [International Red Cross] comes back,” he wrote four days later.

“They are tired of delaying their processes to accommodate” the U.S. government, one law enforcement official wrote on April 20. “This stems from Human Rights Org scrutiny they get and pressure from their judiciary.”

Ultimately, Khweis was returned to the United States on June 8, without seeing a Kurdish judge. He is charged with providing and conspiring to provide material support to terrorists.

A spokesman for the U.S. Attorney’s Office for the Eastern District of Virginia declined to comment, saying a response will be filed in court. Khweis’s trial is scheduled to begin May 30.