Pakistan's President Asif Ali Zardari on Sunday issued a decree to prevent actions taken in the past two months by the ex-premier, recently ousted by judges, from being challenged in court.
The Supreme Court on Tuesday ordered the dismissal of Yousuf Raza Gilani as prime minister after convicting him of contempt in April for refusing to reopen Swiss corruption cases against Zardari.
The move was the culmination of a stand-off between the judiciary and the government, and forced the main ruling Pakistan People's Party to hastily elect Raja Pervez Ashraf as the new premier on Friday in a bid to end the crisis.
Sunday's decree aims to prevent actions taken and orders passed by Gilani between April 26 -- when he was convicted of contempt-- and his dismissal this week from being challenged in any Pakistani court, according to the text of the ordinance.
When they ousted Gilani, the Supreme Court said he was no longer prime minister from the date of his contempt conviction, raising the prospect of any actions he took as premier in the past two months being challenged.
"Any actions taken, orders passed, directions issued, advice given to president or appointments made by Yousuf Raza Gilani, shall be deemed to have been validly done," the ordinance said.
"The provisions of the ordinance shall have, and shall be deemed to always have had, effect accordingly."
It said that "no suit, prosecution or any other legal proceedings including a petition shall lie in any court or forum including the Supreme Court" against any order made or functions performed by the former premier.
The PPP government, dogged by corruption allegations, has been locked in a stand-off with the judiciary for years.
Zardari was forced to ditch his first choice to replace Gilani, Makhdoom Shahabuddin, after an anti-narcotics court ordered his arrest over a drugs scandal.