By Richard Lister
BBC News, Washington
About 60 Guantanamo detainees have been cleared for release
Ordering the closure of the prison at Guantanamo Bay was the easy bit.
Working out what to do with the 245 or so inmates who are still there will be much harder.
The Obama administration has a number of options, but none of them will satisfy everybody.
Some have called for all of the inmates to be released.
This simply will not happen, for a number of reasons.
Returned to fight
First, President Obama believes that among the inmates are at least some who present a genuine threat to the United States.
The Pentagon said recently that 61 former Guantanamo prisoners have returned to fight the US and its allies in places like Iraq and Afghanistan.
At least one, a Kuwaiti named Abdullah Salih al-Ajmi, appears to have carried out a suicide bombing in Mosul last year.
The five detainees charged with involvement in the 9/11 attacks - including the alleged mastermind Khaled Sheikh Mohammed - have said they want to plead guilty to the charges.
There seems to be no prospect of their being released without first facing some kind of judicial process.
So, will the new administration start by releasing those prisoners who are not thought to present a threat?
Well, the Bush Administration tried to do just that.
Intelligence officials have already cleared about 60 Guantanamo inmates for release, but most would still face persecution in their home nations and other countries have been unwilling to accept them.
Albania previously accepted five Chinese Uighurs released from Guantanamo, and Portugal and Switzerland have suggested that they would be prepared to help.
Some detainees have already been taken by third countries
But European Foreign Ministers meeting in Brussels on 26 January will find themselves under pressure to do more, having pressed so hard for the prison's closure.
It looks likely, therefore, that many inmates will be moved to detention centres in the US.
There are several military prisons which could receive them while they are processed for release or trial.
But it is not a popular option in the US, where polls suggest a majority of people do not want them brought onto American soil.
A recent CNN/Opinion Research Corporation poll suggested that the country is split roughly down the middle about whether the Guantanamo prison should even be closed.
If Barack Obama is to fulfil his pledge to both keep America safe and observe its system of justice, his administration will have to set up alternative ways of prosecuting them.
But his decision to suspend the military tribunal system at Guantanamo has already come under fire from such senior Republicans as his former campaign adversary Senator John McCain.
Mr McCain released a statement saying that - in the absence of any other process - the tribunals should have been allowed to continue their work.
Even the Bush administration appeared to concede tacitly that it was unlikely to be able to prosecute more than a small proportion of those held at Guantanamo successfully.
Evidence to sustain prosecutions was either lacking, or tainted by the way in which it was procured - through torture, coercion or sensitive intelligence methods that the intelligence community might be reluctant to reveal in court.
This raises the question of what happens to those who may well be intent on attacking the US but cannot be prosecuted successfully.
House Republican Leader John Boehner has said he is concerned that some of those "let go too soon could end up back on the battlefield".
Keeping them indefinitely at a detention centre somewhere in the US opens President Obama to the charge that he has simply changed the location without removing the injustice.
The new president wants to ensure that whatever system replaces the Guantanamo process will allow the innocent to be freed and the guilty to be successfully prosecuted, that it will keep America safe and be approved by the Supreme Court.
It is a tall order.