For many years, Hosni Mubarak was the target of Islamist extremists, including al-Qaida, committed to overthrowing him by force.
Al-Qaida leader Osama bin Laden's chief lieutenant, Ayman al-Zawahiri, is an Egyptian who was long associated with violent attacks there. So far, though, the terrorist group has been silent on the popular, nonviolent uprising in Egypt.
"For now, at least, it's quite a blow to bin Laden's ideology," says Daniel Byman, a terrorism expert at Georgetown University. "What Egypt shows is that peaceful demonstrations, peaceful protests can topple autocratic governments that are quite repressive.
"This is a direct refutation of bin Laden's claim that only violence will work to effect political change."
The implication of the recent events in Egypt was not lost on President Obama. He spoke from the White House last Friday after it was learned Mubarak was stepping down after nearly three decades in power.
"Egyptians have inspired us, and they've done so by putting the lie to the idea that justice is best gained through violence," he said. "For in Egypt, it was the moral force of nonviolence, not terrorism, not mindless killing, but nonviolence, moral force, that bent the arc of history toward justice once more."
Egypt has been central to al-Qaida's narrative of repression and political change in the Arab world. Zawahiri was a member of the extremist group Egyptian Islamic Jihad, which was responsible for the assassination of President Anwar Sadat in 1981. Zawahiri was jailed for three years.
That and other terrorist attacks in the 1990s prompted Mubarak to intensify his strong-arm tactics.
Bin Laden's Nightmare
Zawahiri joined bin Laden and al-Qaida, and in a challenge to Mubarak and other Arab leaders like him, they formulated an ideology based on Islamist militancy and violence.
Shibley Telhami, a professor of Middle East studies at the University of Maryland, says al-Qaida argued that ousting a figure like Mubarak could only come about through force.
"What we've seen here is exactly the opposite: that the people of Egypt and really the people of Tunisia have done so peacefully, in a manner that bin Laden has not been able to do in any country by force," he says.
Telhami calls the recent events in Egypt bin Laden's nightmare. But he cautions that the process is not yet complete and hardly irreversible.
"If, in fact, this experiment, this revolution, succeeds, and people see that these peaceful demonstrations are bringing about change, al-Qaida's power will diminish considerably," he says.
The risk, of course, is that there will not be a smooth pathway to democratic and representative government. Some fear the possibility that the Muslim Brotherhood, the oldest Islamist group in Egypt, may be a stalking horse for militancy. The Brotherhood and al-Qaida trace their foundation to some common sources. But there are big differences between them, Byman says.
"One of the biggest is that the Brotherhood has renounced jihad and violence. And skeptics may say that was simply tactical, that it was forced to do so. But nevertheless, that renunciation in Egypt was something that Zawahiri and al-Qaida have been quite critical of," Byman says.
Still, the aftermath of revolution has rarely been untroubled. Should Egypt descend into political chaos, it could present an opportunity for bin Laden and other extreme groups, he says.
"The biggest risk is that if the revolution in Egypt fails ... [it] will vindicate bin Laden ... will show his message — that there should have been an organized jihadist leader of this — it will show that to be correct," Byman says.
Before the recent events in Egypt and Tunisia, al-Qaida's prospects seemed to be on the rise in Pakistan and in Yemen. But at the center of the Arab world, al-Qaida's influence had weakened in the decade since the attacks of Sept. 11, 2001. It seems for the moment that the events in Egypt and Tunisia will only weaken it further.