Khalid Sheik Mohammed, the self-proclaimed mastermind of the Sept. 11, 2001, attacks, will probably remain in military detention without trial for the foreseeable future, according to Obama administration officials.

The administration has concluded that it cannot put Mohammed on trial in federal court because of the opposition of lawmakers in Congress and in New York. There is also little internal support for resurrecting a military prosecution at Guantanamo Bay, Cuba. The latter option would alienate liberal supporters.

The administration asserts that it can hold Mohammed and other al-Qaeda operatives under the laws of war, a principle that has been upheld by the courts when Guantanamo Bay detainees have challenged their detention.

The White House has made it clear that President Obama will ultimately make the decision, and a federal prosecution of Mohammed and four alleged co-conspirators has not been ruled out, senior officials said. Still, they acknowledge that a trial is unlikely to happen before the next presidential election and, even then, would require a different political environment.

Attorney General Eric H. Holder Jr. said this week that a decision on a trial for Mohammed was close. Other administration officials said that his remark was simply a stock response to a frequently asked question and that it didn't signal that any announcement was imminent.

After Holder spoke, Democratic Sen. Charles E. Schumer and Republican Rep. Peter King, both of New York, reiterated their opposition to a Sept. 11-related trial anywhere in New York state, as did the state's governor-elect, Andrew Cuomo. Lawmakers and officials in the state have cited concerns about a trial's cost as well as security issues.

Administration officials think opposition would be as entrenched in Virginia and Pennsylvania, the other viable federal districts for a trial, given that deaths on Sept. 11 occurred at the Pentagon and on United Flight 93.

Holder "says soon. Schumer says never. It's somewhere between the two," said a senior administration official who, like other officials, would discuss internal deliberations only on the condition of anonymity.

A Justice Department spokesman declined to comment.

Mohammed was captured in Pakistan in March 2003 and was held at secret CIA prisons overseas until he was transferred in September 2006 to Guantanamo Bay. He is held there with a group of high-value detainees at a small, highly secure facility.

The Bush administration first brought charges of capital murder and war crimes in February 2008 against the Pakistani national, who was raised in Kuwait. But the Obama administration suspended legal proceedings at Guantanamo Bay and in January 2010 withdrew military charges against Mohammed and four others in anticipation of a federal trial in Manhattan.

Obama came into office with a strong preference to prosecute Mohammed and other detainees in federal court as part of a larger plan to close the military prison at Guantanamo Bay. Almost from the start, however, he ran into fierce political opposition.