Military judges at the US detention camp at Guantanamo Bay in Cuba have dismissed all charges against the only two captives currently facing trial.
However Canadian-born Omar Ahmed Khadr and Salim Ahmed Hamdan from Yemen will remain in legal limbo in southeast Cuba along with 380 other detainees.
Mr Khadr, from Toronto, was just 15 when he was captured in Afghanistan. He is accused of killing a US army medic. Mr Hamdan has previously admitted being a driver and bodyguard for al-Qaeda leader Osama bin Laden.
In both rulings, the judges found that they had no jurisdiction to proceed, as neither man had been classified as an 'unlawful enemy combatant' as required by a recent US law. The strict definition was passed by US Congress last year.
The rulings could make it more difficult to try any of the other prisoners at the base in the near future.
It is the latest setback for the Bush administration's efforts to put the Guantanamo captives through some form of judicial process.
The rules were rewritten last year after the US Supreme Court deemed the old tribunals to be illegal.
Defence lawyers and Amnesty International have called for any future trials to be moved to the regular US federal courts system.