A federal judge has blocked a federal law allowing the government to indefinitely detain terrorism suspects, extending an earlier ruling that marked a clear challenge to the recently enacted National Defense Authorization Act of 2011.

Southern District of New York judge Katherine Forrest issued a temporary injunction in May, backing a group of activists and journalists who maintained that a provision in the new defense spending bill violated their rights. The bill codified the federal government's authority to indefinitely hold people who had "substantially" or "directly" supported the perpetrators of Sept. 11 attacks or "associated forces."

Forrest extexnded her injuction Wednesday, and the U.S. attorney in Manhattan filed an appeal Thursday, Bloomberg reported.

The government has been detaining terrorism suspects for a decade by invoking a Congressional joint resolution, known as an Authorization for the Use of Military Force, or AUMF, that empowered the government to pursue affiliates and allies of the terrorists who carried out the Sept. 11, 2001, attacks. The Obama administration has argued that the National Defense Authorization Act of 2011 simply reaffirmed that authority.

But civil liberties advocates pushed back, arguing that the new legislation broadened the scope of people the government could legitimately detain without trial. They pointed to ambiguous language in the bill that seemed to allow the government to hold American citizens captured on U.S. soil.

The group of plaintiffs who sued claimed that they engaged in activities that could expose them to indefinite detention. Journalist Chris Hedges, for example, has reported stories that involved interviewing members of terrorist organizations; activist Kai Wargalla said she endangered herself through her work on behalf of pro-transparency organization Wikileaks.

Forrest supported their claim, writing that the plaintiffs had a legitimate fear of detention and saying language in the NDAA was "overbroad, as well as impermissibly vague."

"The due process rights guaranteed by the Fifth Amendment require that an individual understand what conduct might subject him or her to criminal or civil penalties," Forrest wrote. "Here, the stakes get no higher: indefinite military detention -- potential detention during a war on terrorism that is not expected to end in the foreseeable future, if ever. The Constitution requires specificity -- and that specificity is absent."

Forrest said that the statute violates First Amendment protections and fails to provide constitutionally guaranteed due process. She also said that the new law, rather than merely solidifying existing law, attempted to broaden the president's authority.

The statute in question "appears to be a legislative attempt at an ex post facto 'fix': to provide the president [in 2012] with broader detention authority than was provided in the AUMF in 2001 and to try to ratify past detentions, which may have occurred under an overly broad interpretation of the AUMF," Forrest wrote.