A spokesman for the National Security Council declined to comment.

President George W. Bush opened the military prison in Cuba in January 2002 to hold and interrogate detainees from the Afghanistan War. It sent about 780 men there for indefinite detention without trial. A few were eventually charged by the military commission system that Mr. Bush established there, which has achieved several convictions through plea deals but has struggled to hold contested trials.

After Guantánamo’s image became toxic worldwide, and the Supreme Court ruled that the judicial branch could hear habeas corpus lawsuits by the detainees, Mr. Bush began trying to close the prison. In 2009, Mr. Obama inherited about 242 detainees and continued that policy, directing the government to close the prison within a year.

However, Congress blocked Mr. Obama’s plan to bring several dozen detainees — who were deemed untriable but unable to be released — to a domestic prison in the United States. Still, arguing that Guantánamo was too expensive and fueled anti-Americanism, Mr. Obama chipped away at its population; 41 remained when he left office.

Five detainees are on a list recommended for transfer to stable countries — including one each from Algeria and Morocco, which have already taken back many others. Mr. Trump, who called for ending all transfers because of the risk of recidivism, has given no sign that he will permit their repatriations.

Still, the Trump administration may soon repatriate a Saudi, Ahmed Muhammed Haza al-Darbi, under a February 2014 plea deal with military commissions prosecutors. He promised to cooperate as a witness in return for being repatriated after three and a half years to serve the remainder of his nine-to-15-year sentence in Saudi Arabia. Mr. Darbi testified this month in videotaped depositions for use in future trials.

Since its first week in office, the administration has internally circulated various drafts of a detention order. Those efforts slowed, however, after Congress and military and intelligence officials pushed back against ideas in early drafts, like reopening the C.I.A.’s overseas “black site” prisons where the Bush administration tortured terrorism suspects.

The White House dropped that and several other ideas, but as the drafts were watered down, momentum to finish the job faltered. Meanwhile, the administration has brought no new detainees to Guantánamo, despite Mr. Trump’s campaign vow to fill the prison back up.