President Barack Obama signed on New Year's Eve a bill that gives the military authority to detain American citizens indefinitely and without criminal charge, breaking with the stroke of a pen one of his many campaign promises, even as he pledged that the new powers the bill grants will not be applied to U.S. citizens.

The provision was just one part of a massive $662 billion defense spending authorization that funds the military, penalizes Iran's central bank and freezes military aid to Pakistan, among other things.

The president's opponents in Congress, including some Democrats, attached the indefinite detention provision to force the administration to either accept a much heavier load of terrorism suspects, many who would be heading to the Guantanamo Bay military prison, or veto the bill and stand accused of opposing funds for the troops.

President Obama issued a veto threat after a provision was added that required all terrorism suspects be automatically rendered into military custody -- a fundamental change to the criminal justice system that members of the administration warned could stymie other agencies or put investigations at risk.

Obama agreed to sign it after language was left in the bill that allows the administration to dedicate terror prisoners to civilian courts instead of military custody. In its final form, the bill stipulates that all terrorism suspects are to be handled by the military unless the administration decides otherwise and explains its reasoning to Congress.

"My administration will not authorize the indefinite detention without trial of American citizens," President Obama said in a signing statement, a tactic presidents occasionally use to clarify how they interpret laws. "Indeed, I believe that doing so would break with our most important traditions and values as a Nation. My Administration will interpret section 1021 in a manner that ensures that any detention it authorizes complies with the Constitution, the laws of war, and all other applicable law."

Obama went on to explain that as he understands the indefinite detention provision, his administration is being given "broad authority to determine how best to implement it," which he said would be used to ensure American citizens are exempt.

"I reject any approach that would mandate military custody where law enforcement provides the best method of incapacitating a terrorist threat," Obama wrote.

"As my Administration has made clear, the only responsible way to combat the threat al-Qa'ida poses is to remain relentlessly practical, guided by the factual and legal complexities of each case and the relative strengths and weaknesses of each system. Otherwise, investigations could be compromised, our authorities to hold dangerous individuals could be jeopardized, and intelligence could be lost. I will not tolerate that result, and under no circumstances will my Administration accept or adhere to a rigid across-the-board requirement for military detention."

The signing statement, while likely a relief to some of the president's more liberal allies, will not assuage all criticism. As one writer for the progressive blog FireDogLake pointed out, future administrations may interpret the law differently, applying a wholly new standard of who should or should not be held in military custody.

"President Obama's action today is a blight on his legacy because he will forever be known as the president who signed indefinite detention without charge or trial into law," Anthony D. Romero, executive director of the American Civil Liberties Union, explained in a media advisory. "The statute is particularly dangerous because it has no temporal or geographic limitations, and can be used by this and future presidents to militarily detain people captured far from any battlefield.  The ACLU will fight worldwide detention authority wherever we can, be it in court, in Congress, or internationally."

"We are incredibly disappointed that President Obama signed this new law even though his administration had already claimed overly broad detention authority in court," he added. "Any hope that the Obama administration would roll back the constitutional excesses of George Bush in the war on terror was extinguished today."