The violence in Libya - and an earlier assault by 2,000 people on the US embassy in the Egyptian capital Cairo - were sparked by a 14-minute trailer for a film called The Innocence of Muslims posted on YouTube.
In an original English version and another dubbed into Egyptian Arabic, Prophet Mohammed has been denigrated.
It was made by Sam Bacile, a 56-year-old California real estate developer who identifies himself as an Israeli Jew.
He said he had produced, directed and written the two-hour film which had only been shown once to a mostly empty theater in Hollywood earlier this year.
'Islam is a cancer, period,' he said in an interview yesterday, speaking after the State Department confirmed the death of an American in Benghazi.
He was apologetic about the killing but blamed lax embassy security and the perpetrators of the violence. 'I feel the security system (at the embassies) is no good,' said Bacile. 'America should do something to change it.'
Bacile claimed he did not know who had dubbed the film into Arabic. He went into hiding after the full scale of the the trouble in North Africa became clear.
Yesterday, Morris Sadek, an Egyptian-born Christian in the U.S. known for his anti-Islam views, told AP from Washington that he was promoting the video on his website and on certain TV stations, which he did not identify.
The film has featured on Egyptian media reports for several days with ultraconservative clerics going on air to denounce it and also to attack Sadek, who they blamed for the film.
Matters came to a head yesterday when hundreds of mainly ultraconservative Islamist protesters in Egypt marched to the US Embassy in downtown Cairo, gathering outside its walls and chanting against the movie and the US.
Most of the embassy staff had left the compound earlier because of warnings of the upcoming demonstration.
The crowd chanted, 'Islamic, Islamic. The right of our prophet will not die.'
Some shouted, 'We are all Osama,' referring to al-Qaida leader bin Laden.
Young men, some in masks, sprayed graffiti on the walls. Some grumbled that Islamist President Mohammed Morsi had not spoken out about the movie.
A group of women in black veils and robes that left only their eyes exposed chanted, 'Worshippers of the Cross, leave the Prophet Mohammed alone.'
Dozens of protesters then scaled the embassy walls, and several went into the courtyard and took down the American flag from a pole. They brought it back to the crowd outside, which tried to burn it, but failing that tore it apart.
The protesters on the wall then raised on the flagpole a black flag with a Muslim declaration of faith, 'There is no god but God and Mohammed is his prophet.' The flag is commonly used by ultraconservatives around the region.
The Cairo embassy is in a diplomatic area in Garden City, where the British and Italian embassies are located, only a few blocks away from Tahrir Square, the center of last year's uprising that led to the ouster of Mubarak.
The U.S. Embassy is built like a fortress, with a wall several metres high. But security has been scaled back in recent months, with several roadblocks leading to the facility removed after legal court cases by residents.
Trouble quickly spread to Libya where a group identifiying itself as the 'Islamic Law Supporters' attacked the consulate on the anniversary of the 9/11 attacks on American in protest at a film that they deemed blasphemous to the Prophet Mohammed.
A furious mob fired gunshots and then set the building alight as they clashed with Libyans hired to guard the facility. Outnumbered by the crowd, Libyan security forces did little to stop them, al-Sharef said.
Witnesses reported militants firing rocket-propelled grenades from a nearby farmhouse.
The situation rapidly deteriorated as the army tried to cordon off the area around the building and fought running battles with the attackers. But the crowd overwhelmed the facility, looting the contents.
'I heard nearly 10 explosions and all kinds of weapons. It was a terrifying day,' said a witness who refused to give his name because he feared retribution.