In his weekly radio address, President Obama paid tribute to the Americans killed in Libya and denounced the violence and anti-U.S. mob protests apparently sparked by an anti-Muslim video.
Among the four killed was Chris Stevens, the first U.S. ambassador to die in an attack since 1979.
"Without people like them, America could not sustain the freedoms we enjoy, the security we demand, and the leadership that the entire world counts on," Obama said in his weekly radio and Internet address Saturday.
The theme echoed comments by the president in recent days, including at a ceremony Friday at Andrews Air Force Base marking the return of the four men's remains.
The remarks allowed Obama to emphasize his role as commander in chief less than two months before the presidential election and draw attention to foreign policy, an area where he wins more approval from voters that his rival, Mitt Romney.
Muslims angry over the film produced in the U.S. denigrating the Prophet Muhammad took the streets on Friday in more than 20 countries from the Mideast to Southeast Asia, and at least six people were killed. A day earlier, four Yemeni demonstrators were killed in protests that turned violent at the U.S. Embassy in Sanaa.