Syria descended one step closer to civil war over the weekend, as warships parked off the coast of the Mediterranean city of Lattakia and shelled the civilian population in retaliation for the anti-government protests that have swept the city.

In Libya, rebel forces seized control of the town of Zawiyah, about 50km to the west of Tripoli. By gaining control of the town, the rebels have effectively cut of the capital - and the stronghold of the Gaddafi regime - from the outside world; with eastern Libya under rebel control, the western highway linking Tripoli to Tunisia was the only supply route for the city. Rebels can now intensify their siege of Tripoli.

Sieges and bombardment from the sea: these are the endgames of two of the most stubborn regimes to face the wrath of their people in the year of Arab revolutions. Leaders in both countries have determined opposition to their rule is equal to an existential threat to the nation itself, and their compliant armies responded accordingly.

In Egypt, where the army remained relatively impartial during the 18 days of protest that led to the resignation of the president, a different kind of endgame is taking place. While Egypt's opposition was spared the bloodshed of an army willing to use heavy weaponry against its people, they were left with an army and security system that forms its own independent power structure, deeper in many ways than that of the presidential family that ruled the country for 30 years.

Bringing the army under civilian rule and dismantling the country's byzantine security services will be a longer, and tougher, challenge than forcing the resignation of the president, the opposition are discovering. The Supreme Council of Armed Forces (SCAF), the military council that has ruled Egypt since Mubarak's resignation, has had a complex relationship with the protest movement; that relationship has now all but collapsed after the council announced plans for a military trial for a key protest leader on Sunday.

Asmaa Mahfouz was summoned to a security building for questioning on Saturday and told she would face military trial, reportedly for comments made on her Twitter account. Mahfouz is one of the most prominent of the young, tech-friendly activists who championed the January 25 protest movement. Her video posting to YouTube, one week before the protests began, is a seminal part of the revolution's history.

The military trial for a civilian activist - already condemned by opposition leaders including former IAEA chief Mohamed Elbaradei - highlights the risk that the SCAF will be unable - and possibly unwilling - to run legitimate elections and oversee the drafting of a new constitution. A boycott of this process by the liberal activists that kickstarted the revolution would be truly disastrous, as we have said before.

In fact, many of those activists now think that the military council itself needs to be overthrown. And its authoritarian methods of dealing with activists like Mahfouz do indeed paint a grim picture of the outlook for transition to civil rule: there is no reason to think a military that tries civilians in military courts on political charges will voluntarily step back from such intrusion into public life. In that sense, Egypt's army has provided the less violent mirror image of Gaddafi in Libya and Assad in Syria - unwilling to step back without a fight. As Mouin Rabbani wrote in Jadaliyya back in May, summing up the state of the Arab uprisings:

Time and again, relatively modest demands that could have easily been addressed without affecting the existence or structure of the regime have instead been met with brutality and contempt, thus producing popular revolts calling for the ouster of the regime. One after the other, Arab rulers and their security forces are producing dynamics which rapidly eliminate any middle ground and leave victory or destruction as the only possible outcomes.

Egypt's struggles matter not just because it is the Arab world's biggest and most culturally influential country: they will be the struggles that face civilians in Libya, Syria and Yemen as they transition to a civilian state and face the implicit power wielded by those holding the weapons. The endgame is on.


Sunday in the Middle East is a weekly column. FT Tilt's MENA correspondent Tom Gara takes a birds-eye view of the Middle East as the region undergoes its most dramatic transformation in decades. See all our Sunday in the Middle East columns via this link - you can also subscribe by email.