President Barack Obama has said politicians in the US need to go further after Congress relaxed some restrictions on transferring detainees from the US prison at Guantanamo Bay, Cuba, to the custody of foreign governments.

After signing the National Defence Authorisation Act for the US 2014 federal budget, Obama noted that Congress retained regulations that prevent the transfer of prisoners to American soil, where they could be tried in federal court.

"The executive branch must have the authority to determine when and where to prosecute Guantanamo detainees," Obama said in a signing statement released during his Hawaiian holiday.

Prosecuting alleged terrorists in US federal court is "a legitimate, effective, and powerful tool in our efforts to protect the nation," Obama said.

The United States also needs "flexibility, among other things, to act swiftly in conducting negotiations with foreign countries regarding the circumstances of detainee transfers," Obama said.

The regulations could remain an obstacle to the administration's years-long bid to close the Guantanamo Bay prison, where 158 detainees from various countries remain after years of detention without trial at the US Naval Base in Cuba.

The prison has been condemned internationally.

While politicians of both political parties refused to yield on the ban against bringing prisoners to the United States, they were willing to relax rules for sending prisoners to their home countries.

Among the earlier restrictions was that the administration had to certify that the country where an inmate was being sent was not "facing a threat that is likely to substantially affect its ability to exercise control over the individual."

Restrictions lifted

This had all but ruled out politically chaotic Yemen, which is home to the largest group of Guantanamo detainees.

Transfers had also been banned to countries that Washington designated "state sponsors of terrorism," which made it difficult to move Syrian inmates.

And prisoners in the past also could not be sent back to any country where previously released Guantanamo detainees had returned to "terrorist activity."

Such rules will be lifted or significantly relaxed under the new law.

Even before the legislation was enacted, the administration had become more active in making transfers, sending two detainees each to Sudan, Saudi Arabia and Algeria.