Speaking at a ceremony making the anniversary of the airliner crash into the Pentagon, Obama called al Qaida "a sorry band of men that perverts religion" and said any aims they had of triggering a war against all of Islam would fail.
Obama spoke against a backdrop of new controversy over a proposed Muslim cultural center and a mosque near Ground Zero in Lower Manhattan. Critics say establishing a Muslim presence near the site of an attack carried out by Muslim extremists is an insult and provocation.
"Just as we condemn intolerance and extremism abroad, so will we stay true to our traditions here at home as a diverse and tolerant nation," Obama said at the event, which was attended by Secretary of Defense Robert Gates and a large number of military personnel.
The president also called maintaining tolerance and freedom in the United States a lasting tribute to those killed. "This is how we will keep alive the legacy of these proud and patriotic Americans," he said. "This is how we will prevail in this great test of our time."