The U.S. ambassador to Libya and three other embassy staffers were killed Tuesday night in a rocket attack that targeted the envoy's car in the eastern Libyan city of Benghazi.

A Libyan official told Reuters on Wednesday that "the American ambassador and three staff members were killed when gunmen fired rockets at them." Al Arabiya, citing Interior Ministry sources, reported that the ambassador, Christopher Stevens, died of suffocation during the attack.

The incident occurred on Tuesday evening when armed gunmen attacked the U.S. consulate compound in Benghazi, clashing with Libyan security forces before the latter withdrew as they came under heavy fire. Reuters reporters on the scene could see looters raiding the compound, walking off with desks, chairs and washing machines.

According to a Libyan Interior Ministry official, the armed men stormed the U.S. consulate and set it ablaze, in protest against a film deemed insulting to Islam's prophet, Mohammed, which was reportedly produced in America.

The Libyan doctor who treated the ambassador, Ziad Abu Zeid, said on Wednesday that Stevens was brought to the Benghazi Medical Center by Libyans the night before, with no other Americans, and that initially no one realized he was the ambassador.

Abu Zeid said Stevens had "severe asphyxia," apparently from smoke inhalation, causing stomach bleeding, but had no other injuries.

An Israeli filmmaker, responsible for the movie attacking Islam's Prophet Muhammad that sparked the angry assaults went into hiding on Tuesday.

Speaking by phone from an undisclosed location, writer and director Sam Bacile remained defiant, saying Islam is a cancer and that he intended his film to be a provocative political statement condemning the religion.

U.S. President Barack Obama strongly condemned the "outrageous attacks," and promised to ensure that all necessary resources would be available for the security of U.S. staff around the world. Obama also said that the U.S. rejects denigration of religious beliefs but opposes the "senseless violence" that killed U.S. diplomats in Libya.

American ­officials said on Wednesday that some 50 Marines are being sent to Libya to reinforce security at U.S.­ diplomatic facilities in the aftermath of the attack.

The Marines are members of an elite group known as a Fleet Antiterrorism Security Team, whose role is to respond on short notice to terrorism threats and to reinforce security at U.S.­ embassies worldwide.

The officials who disclosed the plan to send the Marines spoke on condition of anonymity because they were not authorized to speak publicly.

Libyan leader Mohammed Magarief apologized to the U.S. over the attack in a news conference broadcast live on Al Jazeera television. "We apologize to the United States, the people and to the whole world for what happened," he said.

A senior Libyan official later accused supporters of the late Libyan leader Muammar Gadhafi of carrying out the attack.

Deputy Interior Minister Wanis al-Sharif told a news conference in Benghazi that the attackers had used rocket-propelled grenades. "There were RPGs... which shows there were forces exploiting this. They are remnants of the [former] regime," he said.

He suggested that the attackers could have been acting in revenge for the extradition from Mauritania this month of Gadhafi's former intelligence chief Abdullah al-Senoussi.

Gadhafi was ousted by rebel forces backed by NATO air power in August 2011 and was killed in October after months as a fugitive.

The attack in Libya came hours after ultraconservative Islamist demonstrators in Egypt climbed the walls of the U.S. Embassy in Cairo to protest a film being produced by Egyptian Coptic Christians living in the U.S.

According to the State Department website, Ambassador Christopher Stevens arrived in Tripoli in May 2012. The website says that Stevens served twice in Libya in the past, both as Special Representative to the Libyan Transitional National Council from March 2011 to November 2011, during the Libyan revolution, and as the Deputy Chief of Mission from 2007 to 2009.