Cairo: Several thousand Egyptian Islamists rallied for an overhaul of the judiciary on Friday, after a court challenged a decision by Islamist President Mohamad Mursi to sack the veteran state prosecutor.

Mursi’s Muslim Brotherhood movement had called the demonstration outside the Supreme Court in central Cairo to demand reform of the judiciary, which has repeatedly challenged Mursi since he took office last June.

“The people demand the cleaning up of the judiciary,” the protesters chanted.

A court last month overturned a controversial decree by Mursi to sack state prosecutor Abdul Mejeed Mahmoud, appointed by ousted president Hosni Mubarak, and replace him with Talaat Abdullah.

The court believed Mursi had overstepped his powers when he sacked Mahmoud, blamed for bungling the trials of former regime officials, including Mubarak himself, after the 2011 uprising.

Mursi’s supporters say many judges are Mubarak-era appointees who remain hostile to them despite their subsequent election victories.

A court also overturned Mursi’s calling of parliamentary polls for this month, ruling that he had ratified a new electoral law without consulting the constitutional court.