By Michelle Moghtader
DUBAI (Reuters) - Iran's Supreme Court has banned an ally of former President Mahmoud Ahmadinejad from holding public office for five years over his role in the 2009 deaths of three anti-government protesters, Iranian media said on Sunday.
Saeed Mortazavi, who was also barred for life from holding any judicial post, used his position as prosecutor general in Tehran to help stamp out dissent following the disputed re-election of Ahmadinejad in 2009.
The ruling represents another stain on the record of Ahmadinejad, whose second term in office was tarnished by repeated allegations of mismanagement and human rights abuses.
Iran's semi-official Mehr news agency quoted Mortazavi as saying he would appeal, citing Article 18 of Iranian judicial law which grants people convicted in such cases a final review.
The Supreme Court upheld a lower court ruling from last year that found Mortazavi and two deputies guilty of filing false reports and issuing unlawful arrest orders against protesters, who were then transferred to the notorious Kahrizak prison.
The case revolved around three men, including the son of a prominent conservative politician, who were tortured to death in the prison after they were detained during mass street protests against the 2009 elections, which the opposition said were rigged in favor of Ahmadinejad.
Iran's Supreme leader Ayatollah Ali Khamenei ordered the closure of the Kahrizak jail later the same year and Mortazavi was suspended from his post in 2010 over the allegations of wrongdoing.
Dubbed by critics as "the butcher of the press", Mortazavi played a central role in shutting down reformist newspapers and arresting dozens of journalists during his time as Tehran’s prosecutor general from 2002-2009.
He was also involved in the case of Iranian-Canadian photographer Zahra Kazemi, who died in custody in 2003 -- a death which strained relations between Tehran and Ottawa.
Human Rights Watch has previously described Mortazavi as a "serial human rights abuser" whose "unsavory history goes back many years". Earlier this year, he was charged with corruption while running the Social Security Organization in 2012.
Mortazavi's arrest and trial were seen by many as a sign of Khamenei's dwindling support for Ahmadinejad, who was replaced as president by Hassan Rouhani following elections in 2013.
(Editing by Crispian Balmer)