An Egyptian court sentenced ousted president Hosni Mubarak and his two sons to three years in prison on Saturday after a retrial for embezzlement.

Mubarak and his sons Alaa and Gamal were present in the caged dock, wearing suits and sunglasses. Mubarak’s lawyers may try to appeal the verdict.

They had already been sentenced to three years on the same charges but an appeal court overturned the original verdict.

ADVERTISEMENT

It was not immediately clear whether the sentencing took into account time served. The three had all been arrested in 2011, months after Mubarak was toppled in a popular 18-day uprising after three decades in power.

Mubarak waved at his supporters in the benches before the judge read his verdict.

He and his sons were also fined 125 million pounds ($16 million) — the amount they were accused of embezzling from funds meant for the maintenance of presidential palaces.

They also have to give back 21 million pounds, the court ruled.

Mubarak will return to the Cairo military hospital where he has spent much of his time since his detention.

ADVERTISEMENT

Before Saturday’s verdict, he and his sons had been free men after their pretrial detention period expired.

Mubarak, who turned 87 this month, was cleared of charges in another trial over the deaths of protesters during the uprising in January and February 2011.

Seven of his police commanders were acquitted in the trial. The prosecution has lodged an appeal.

ADVERTISEMENT

In the months following his ouster, Egypt’s interim military rulers rounded up top Mubarak-era leaders and police commanders and put them on trial, under pressure from protesters.

Most have since been acquitted, as widespread anger shifted to Mubarak’s now overthrown successor, the Islamist Mohamed Morsi.

ADVERTISEMENT

Morsi, a Muslim Brotherhood leader, was overthrown by the army in 2013 and his movement crushed in a crackdown that left hundreds dead.

He has been sentenced to 20 years in prison over deadly clashes outside his palace during his year in power.

Mubarak was overthrown in one of the regional uprisings that swept the Middle East in 2011 after Tunisian protesters forced their president out.

ADVERTISEMENT

The revolutionary optimism that marked the uprising has given way to fatigue and even nostalgia among many for the stability under Mubarak’s regime.

His former military intelligence chief, Abdel Fattah al-Sisi, is now president.

Sisi overthrew Morsi, who had promoted him to defence minister in a move to purge Mubarak loyalists in the army, after millions protested to demand Morsi’s resignation.

Since then Sisi has crushed the Muslim Brotherhood, once the country’s largest political movement, while restoring the police’s authority after it had all but collapsed in 2011.

ADVERTISEMENT

Critics say the popular leader is reviving the practices of the Mubarak era, which was marred by police abuses and arrests of dissidents.

Sisi has distanced himself from Mubarak, but says the country has little room for chaotic protests as it tries to recover its economy.