Legislation on the government’s handling of detainees is once again causing an outcry on Capitol Hill — and this time, even Democrats are divided.

The latest legislation would mandate military custody for any member of al-Qaeda or its affiliates who is not a U.S. citizen. It would also authorize their indefinite detention without charge, or trial by military commission.

The language in the National Defense Authorization Act has already been backed by the chairman of the Senate Armed Services Committee, Carl Levin (D-Mich.), along with other Democrats on his panel.

But now other key Democrats are urging Majority Leader Harry Reid to not allow the bill to go forward, saying that it would limit the executive branch’s flexibility in handling terrorism cases. In a letter to Reid released Monday, the group of 13 Democrats from the Senate Select Committee on Intelligence and the Judiciary Committee noted that they were echoing objections previously raised by the Obama administration.

“Professionals in the Intelligence Community and law enforcement need the flexibility to use all tools to effectively interrogate, incarcerate, and bring terrorists to justice,” the senators wrote, saying that they concurred with the administration’s view that the provisions as currently written “severely and recklessly undermine” counterterrorism efforts.

The lead signatories are Intelligence Committee chairman Dianne Feinstein (D-Calif.) and Judiciary Committee Chairman Patrick Leahy (D-Vt.).

Last week, Sen. Lindsey O. Graham (S.C.) said that Republicans would insist that the language be kept in the bill.

That puts the legislation in a bit of a logjam, and it’s unclear whether Reid’s office will move ahead with it. A spokesman did not immediately respond to a request for comment.

Meantime, the House version of the National Defense Authorization Act is running into its own opposition, with the administration balking at a provision that would force the prosecution of a number of terrorist offenses in military commissions rather than in federal courts.

“Decisions about the most appropriate forum in which to prosecute a terrorist should be left, case by case, to prosecutors and national security professionals,” the Pentagon’s general counsel, Jeh Johnson, said in a speech recently at the Heritage Foundation. “A flat legislative ban on the use of one system — whether it is commissions or the civilian courts — in favor of the other is not the answer.”