Evoking memories of the demise of ex-army head Sarath Fonseka, who ended up behind bars after trying to run against President Mahinda Rajapakse in 2010, the government in recent months has appeared to be tightening its grip on power.
Foreign Minister G. L. Peiris' slapdown of Chief Justice Shirani Bandaranayake in parliament last week has led analysts to conclude the top judge's days are numbered.
And senior journalist Frederica Jansz, a prosecution witness against Fonseka, has been trying to claim asylum abroad, fearing for her life. She says she was sacked as editor of the Sunday Leader newspaper for resisting demands by its new owner to temper criticism of Rajapakse and his family.
The government's opponents say no one should be surprised that the regime's former friends were now regarded as its enemies.
"The government is all out to suppress anyone who tries to stand up against the executive," opposition lawmaker Suresh Premachandran told AFP.
"This is autocratic behaviour, no question about it."
Bandaranayake, a 54-year-old former professor of law, had been hand-picked for the top judicial job by Rajapakse's government last year. Her husband was also appointed to politically sensitive posts in state financial institutions.
But the relationship is now in tatters, with Peiris telling MPs that the chief justice had flagrantly "violated the constitution" by appointing a junior judge to head up a judicial watchdog.
Analysts say the real reason for the outburst was Bandaranayake's decision to shoot down a bill that sought to take away powers of local bodies and transfer them to a government minister -- who happens to be the president's brother.
Victor Ivan, the author of a book on the relationship between the Sri Lankan government and judiciary, said it was a classic case of friends turning foes after courts started asserting their authority in recent months.
"The judiciary and the executive behaved like very good buddies in the past," Ivan, a former journalist who describes himself as an "outspoken friend of the president", told AFP.
"Now that rulings are going against the government, they are fighting in public.
"It is like two freight trains moving at each other at high speed. Both will be destroyed as a result of this confrontation. It will also undermine public confidence in both institutions."
According to a pro-government website, ruling party backbenchers have been collecting signatures to impeach the chief justice, who has remained silent since Peiris' comments.
In his speech in parliament, Peiris did not say if the justice would be impeached, but added: "If there is arbitrary action (by the judiciary), we need to address that and we need to make sure it won't happen in the future."
The government's anti-graft panel has also filed a corruption complaint against Bandaranayake's husband, Pradeep Kariyawasam, who resigned recently as head of state-run Savings Bank after a controversial share purchase deal.
The push against the Supreme Court head has recalled the fate of Fonseka, who became a national hero after crushing the Tamils in their northern stronghold in 2009 after a 37-year conflict.
Despite his hero status, Fonseka was hauled before the courts in 2010 on charges of "irregularities in military procurements", in what he argued was a ploy to torpedo his political ambitions.
He was swiftly jailed and stripped of his right to contest elections before being granted a presidential pardon in May of this year.
The government's latest stand-off with the judiciary comes at a time when it faces heightened international scrutiny of its rights record amid allegations that up to 40,000 civilians were killed in the final months of fighting with Tamil rebels.
The United Nations Human Rights Council (UNHRC) in Geneva starts its four-yearly review of Sri Lanka on Thursday (November 1).
It is the first debate on Sri Lanka at the UNHRC since a US-led resolution earlier this year urged Colombo to probe war crimes allegedly committed by its troops, ensure reconciliation and good governance.
"Sri Lanka has a difficult job defending its record in Geneva," said moderate Tamil politician and former lawmaker, Dharmalingam Sithadthan.
"The clash with the judiciary will only make it more difficult for the government."