WASHINGTON (Reuters) - U.S. President Donald Trump signed an order on Tuesday to keep open the military detention center at Guantanamo Bay after his Democratic predecessor, Barack Obama, tried unsuccessfully to close the prison that has drawn international condemnation.

In his first State of the Union address to Congress, Trump made clear he was fulfilling a campaign promise to keep operating the prison for foreign terrorism suspects at the U.S. military base at Guantanamo, Cuba.

“I just signed, prior to walking in, an order directing (Defense) Secretary (Jim) Mattis ... to re-examine our military detention policy and to keep open the detention facilities in Guantanamo Bay,” Trump said.

The executive order authorized the U.S. military to add detainees and suggested the possibility that captured Islamic State militants could be sent there for the first time.

Obama signed an order on his first full day in office in 2009 ordering efforts to shutter Guantanamo within a year, but his plan was thwarted by mostly Republican opposition in Congress. Instead, his administration reduced the inmate population to 41 from 242 during his eight years in office.

The prison, which was opened by President George W. Bush to hold suspected militants captured overseas after the Sept. 11, 2001, attacks, came to symbolize harsh detention practices that opened the United States to accusations of torture.

As a presidential candidate, Trump vowed “to load it up with some bad dudes.” Since he became president a year ago, there is no indication any new prisoners have arrived.

Slideshow ( 3 images )

“In the past, we have foolishly released hundreds and hundreds of dangerous terrorists, only to meet them again on the battlefield - including the ISIS leader, (Abu Bakr) al-Baghdadi, who we captured, who we had, who we released,” Trump said in the speech, referring to the Islamic State militant group.

The Syrian Observatory for Human Rights said in July that Baghdadi had been killed. Americans captured him in the beginning of the war in Iraq, and released him a year later, thinking he was a civilian agitator rather than a military threat.

Civil liberties groups immediately denounced the executive order, and the Center for Constitutional Rights said it would file a legal challenge.

“In trying to give new life to a prison that symbolizes America’s descent into torture and unlawful indefinite detention, Trump will not make this country any safer,” said Hina Shamsi, a director at the American Civil Liberties Union.