WASHINGTON -- The U.S. Senate voted overwhelmingly for an accelerated withdrawal of forces from Afghanistan after more than a decade of fighting, reflecting the wishes of a war-weary nation.
The strong bipartisan vote of 62-33 sends a clear message to President Barack Obama and the military as they engage in high-stakes talks about the pace of drawing down the 66,000 U.S. troops there, with a White House announcement expected within weeks.
Although the vote was on a nonbinding amendment to a defense policy bill, its significance could not be discounted.
Sen. Jeff Merkley, the chief sponsor, argued that al-Qaida is stronger in other parts of the world and that nation-building in Afghanistan has gone off track. His measure endorsed Obama's timetable to withdraw all combat troops by the end of 2014 but pressed for a quicker pace, without specifying how that would be achieved.
"It is time to end this war, end the longest war in United States history," Merkley said.
The Senate hopes to wrap up its version of the bill by week's end. It then would have to be reconciled with the legislation the House passed in May. The House bill calls for Obama to maintain a force of at least 68,000 troops through the end of 2014.
Defense Secretary Leon Panetta said Thursday the U.S. will need to keep troops in Afghanistan even after the combat mission ends because al-Qaida is still present in the country and is trying to strengthen its influence.
Panetta would not say how many American troops he thinks will be needed to conduct that mission, nor did he mention a time period.
"The goal here is an enduring presence therefore that will direct itself toward three important missions. One is obviously counterterrorism, to ensure that we continue to go after whatever al-Qaida targets remain in Afghanistan," Panetta told reporters at a Pentagon news conference.
He added that the United States also will have to train and assist the Afghan forces while providing support.
Also on Thursday, the Senate Armed Services Committee approved Obama's choice to be the top military commander in Afghanistan.
The panel cleared the way for the full Senate to vote on Gen. Joseph Dunford, the assistant commandant of the Marine Corps who had directed combat forces in Iraq.
Dunford would replace Gen. John Allen, the current commander in Afghanistan who has been nominated to take charge in Europe. Allen's nomination is on hold as he's ensnared in the sex scandal that led to the recent resignation of CIA director David Petraeus.
Late on Thursday, the Senate revived last year's debate over how to handle terror suspects and whether restrictions interfere with the president's powers as commander in chief.
Lawmakers approved an amendment that would prevent the transfer of detainees held at Guantanamo Bay, Cuba, to prisons in the United States. The vote was 54-41, with several Democrats vulnerable in the 2014 elections voting with Republicans.
Republican Sen. Kelly Ayotte argued that the 166 terror suspects, including Khalid Sheikh Mohammed, the self-styled mastermind of the Sept. 11, 2001, attacks, should remain at the U.S. naval facility and not be transferred to any facility on American soil.
Responding to Ayotte, Democratic Sen. Dianne Feinstein, the chairwoman of the Senate Intelligence Committee, said the United States not only can but has handled terrorist suspects, with 180 now languishing in super maximum prisons. Feinstein complained that the measure would erase the president's flexibility.
"I don't think the right thing to do is to tie anyone's hands," she said.
Democratic Senate Armed Services Committee Chairman Carl Levin, who had pushed for several of the provisions on terror suspects in last year's defense bill, said Ayotte's measure was "unwise in terms of our national security." He also warned that the provision was certain to draw a presidential veto.
In fact, the administration, in threatening to veto the bill, strongly objected to a provision restricting the president's authority to transfer terror suspects from Guantanamo to foreign countries. The provision is in current law.
The White House said the provisions were "misguided when they were enacted and should not be renewed."
Current law denies suspected terrorists, including U.S. citizens seized within the nation's borders, the right to trial and subjects them to the possibility they would be held indefinitely. It reaffirms the post-Sept. 11 authorization for the use of military force that allows indefinite detention of enemy combatants.
An unusual coalition of liberal Democrats and libertarian Republicans backed an amendment by Feinstein that said the government may not detain a U.S. citizen or legal resident indefinitely without charge or trial even with the authorization to use military force or declaration of war.
Feinstein recalled the dark days of World War II when the United States forcibly removed thousands of Japanese-Americans and placed them in permanent internment camps amid unfounded fears that they were spies and a national security threat.
Civil rights groups said the measure did not go far enough, but it was approved on a 67-29 vote with the backing of conservative Sens. Rand Paul and Mike Lee.
The Senate eliminated one provision from the bill that had attracted White House objections. In a strong bipartisan vote Wednesday, senators voted to allow Pentagon investment in alternative fuels.
-- AP National Security Writer Robert Burns contributed to this report.