A federal judge in Washington on Thursday rejected a government effort to sharply limit access between private lawyers and security detainees at the US base at Guantánamo Bay, calling the effort “an illegitimate exercise of executive power.”

In a strongly worded 32-page decision, Chief US District Judge Royce Lamberth ruled that access by lawyers to their detainee-clients at Guantánamo must continue under the terms of a long-standing protective order issued by federal judges in Washington.

Government lawyers had sought approval to displace the court’s protective order with a so-called Memorandum of Understanding (MOU) that would allow military officials to establish and enforce their own rules about when and how detainees could have access to legal counsel.

“The government wants to place itself as the sole arbiter of when a habeas petitioner is ‘seeking’ to challenge their own detention and when a habeas case is ‘impending,’ and thus when they can have access to counsel,” Chief Judge Lamberth wrote. “But access to the Court means nothing without access to counsel.”

The MOU would give the government “final, unreviewable power to delay, hinder, or prevent access to the courts,” the judge said.

“The government actions thus far demonstrate that it cannot be trusted with such power,” Lamberth said.

Legal groups that have worked to provide counsel to detainees praised the judge’s ruling.

“Today’s ruling reaffirms that constitutional rights are not subject to the whim of the executive,” said Vincent Warren, executive director of the Center for Constitutional Rights.

“The new rules came out of the blue and can only be seen as an effort to punish the men at Guantánamo for exercising their right to challenge their detention,” he said. “These rules would have given the government unfettered control over Guantánamo.”

The decision came as a result of a motion filed on behalf of six detainees at Guantánamo. There are currently 163 alleged Al Qaeda or Taliban members being held at the detention facility.

Initially in early 2002, terror suspects were brought to Guantánamo as part of a Bush administration plan to hold them outside the US in order to prevent them from claiming any protections under the US Constitution.

But in a series of court rulings, the US Supreme Court eventually established that Guantánamo detainees enjoy a right to habeas corpus review – the power to challenge the legality of their detention before a neutral judge.

To facilitate those cases, federal judges in Washington have long operated under court-imposed rules permitting – and protecting – the ability of private lawyers to travel to Guantánamo, meet with their clients, and present their cases in court.

This summer, the Obama administration sought to replace those court-made rules with a set of rules drawn up by the government itself. Government lawyers said that once a detainee’s habeas case had been dismissed, the prisoner’s access to counsel for any subsequent legal challenge should be up to the government to grant or refuse.

Administration lawyers said federal judges had no power to address counsel-access issues on an open-ended basis.

Lamberth disagreed. “The government’s reasoning is substantially flawed and confuses the roles of the jailer and the judiciary in our constitutional separation-of-powers scheme,” he said.

“The court is simply not obliged to give the executive the opportunity to create its own counsel-access provisions before stepping in and fashioning such procedures,” the judge said. “To do so would be to allow the government to transgress on the court’s duty to safeguard individual liberty by ‘calling the jailer to account.’ ”

Lamberth said that the judge-issued protective order had been in place for nearly four years “and there is no record that its provisions have threatened classified information or caused any harm to the military’s operation.”

The judge said the protective order did not amount to a permanent injunction. It would remain in place only as long as detainees are held at Guantánamo.

He pointedly added: “Had, for example, the Obama administration closed the Guantánamo Bay detention facility as it promised, the court’s protective order would no longer have any effect.”