President Obama signed a $607 billion annual defense policy bill on Wednesday even though it contained language banning him from closing Guantanamo Bay military prison in Cuba, something he repeatedly promised to do on the campaign trail in 2008.

The president suggested Wednesday that he is now prepared to ignore congressional restrictions and close the prison anyway by claiming constitutional authority.

Aside from the Guantanamo language, Obama praised the National Defense Authorization Act (NDAA) for including "vital benefits for military personnel and their families, authorities to facilitate ongoing [military] operations around the globe, and important reforms to the military retirement system."

But he stressed that he is "deeply disappointed that the Congress has again failed to take productive action toward closing the detention facility at Guantanamo," adding that keeping the prison open "is not consistent with our interests as a Nation and undermines our standing in the world."

While the White House has promised to present a final proposal to Congress to close the prison before Obama leaves office, the president hinted in his signing statement that he may resort to executive action to skirt the ban and close the facility, reports The Hill.

"The executive branch must have the flexibility, with regard to the detainees who remain at Guantanamo, to determine when and where to prosecute them," Obama said, calling the restrictions on prisoner transfers a potentially unconstitutional violation of presidential authority.

"Under certain circumstances, the provisions in this bill concerning detainee transfers would violate constitutional separation of powers principles," he said, reported The Huffington Post.

Obama warned lawmakers that in "the event that the restrictions on the transfer of detainees ... operate in a manner that violates these constitutional principles, my Administration will implement them in a manner that avoids the constitutional conflict."

It's the sixth consecutive year that lawmakers have included language in the NDAA that outlaws the transfer of Guantanamo prisoners to U.S. soil. Of the 107 detainees currently at Guantanamo, nearly half have already been cleared for released and over 50 have never been charged with a crime, but are considered too dangerous to be held in the U.S. mainland, according to The New York Times.

David Remes, a human rights lawyer representing numerous Guantanamo prisoners, told Al Jazeera that transferring detainees is not the issue Obama should be focused on.

"It doesn't matter that Congress has prevented him from bringing detainees to the U.S., only to hold them indefinitely in detention without charge. That's just changing the zip code," Remes said. "What matters is that time after time he let politics stand in the way of sending detainees back to their home countries or resettling them in other countries. That's the great tragedy, and he has only himself to blame."