A US court has upheld President George W Bush's new anti-terror law, agreeing that Guantanamo inmates cannot challenge their imprisonment in courts.
Mr Hamdan had argued the tribunals were unconstitutional
District Judge James Robertson rejected a challenge by Salim Ahmed Hamdan, a former driver of Osama Bin Laden.
Mr Hamdan's case prompted the Supreme Court to strike down the government's policy on detainees last year.
But Mr Bush later signed a new law that established military commissions to try enemy combatants.
Judge Robertson ruled that the new law - signed by Mr Bush in October - removed federal court jurisdiction to hear cases like Mr Hamden.
The verdict is a legal victory for the White House, which has been fending off criticism of the new law from Democrats and civil rights groups.