President Obama’s pledge to close the US terror detention camp at Guantánamo is now facing its most significant obstacle. On Wednesday, Congress gave final approval to a defense authorization bill that includes a provision blocking transfer of any Guantánamo detainees to the US – even to face a criminal trial.

At the same time, the Obama administration is working on an executive order authorizing the indefinite detention of certain terrorism suspects the administration deems too difficult to put on trial but too dangerous to release.

The combination of executive and legislative action suggests that Guantánamo may remain an important fixture in American antiterrorism efforts – despite assertions by Mr. Obama and others that Guantánamo has become an effective recruiting tool for Al Qaeda.

He suggested that he has not given up on his plan to close the detention facility at the US Naval base in Cuba. “I think we can do just as good a job housing them somewhere else,” he said.

The president said closing the prison camp would undercut the negative symbolism of Guantánamo with a more positive message that the US is “living up to our values and our ideals and our principles.”

In the meantime, the administration’s plan to formalize an indefinite detention regime for certain detainees at Guantánamo is drawing criticism from human rights and civil libertarian groups.

“We have serious concerns about any order that would institutionalize indefinite detention for Guantánamo detainees,” said American Civil Liberties Union Washington director Laura Murphy, in a statement. “Where credible evidence exists against Guantánamo detainees, they should be charged and prosecuted under our criminal justice system.”

Obama said a team within his administration has been working to find the right balance between security and legal safeguards for terrorism suspects.

“Releasing [certain Guantanamo detainees] at this stage could potentially create greater danger for the American people,” the president said. “That’s what this team has been looking at: Are there ways for us to make sure these folks have lawyers, to make sure that these folks have the opportunity to challenge their detention, but at the same time making sure that we are not simply releasing folks who could do us grievous harm.”

Of the 174 detainees at Guantánamo, the administration has cleared 90 for transfer to other countries. Thirty-six have been designated for possible prosecution. The remaining 48 are to be held indefinitely without trial.

Congress's passage of a provision preventing any transfer of Guantánamo detainees to the US, even to stand trial, is also drawing fire.

Tom Malinowski, Washington director of Human Rights Watch, called the measure “a reckless and irresponsible affront to the rule of law.”

“By hindering the prosecution of Guantánamo detainees in federal court, Congress has denied the president the only legally sustainable and globally legitimate means to incarcerate terrorists,” he said.