The overnight ruling against men who once wielded immense power in Africa's largest country represents another blow to the legacy of Abdelaziz Bouteflika, who was forced out as president by street protests and the army chief in April.
Also handed a 15-year prison term was the leader of a leftist political party, Louisa Hanoune, for decades a fixture on Algeria's political scene. Her defense lawyer, Mokrane Ait Larbi, told The Associated Press that he would file an appeal, calling the two days of proceedings a "politically driven trial."
All four were arrested in May. The oil- and gas-rich country is now struggling to find a new political path, and protesters have maintained street demonstrations because much of the state apparatus under Bouteflika remains.
In a statement from the town of Blida, the court said seven people were convicted in the closed-door trial in the town of Blida, with three of them, believed to have fled the country, convicted in absentia and sentenced to 20 years in prison.
Among the four held were Said Bouteflika, brother and special counsellor of Bouteflika, and former intelligence figures Gen. Athmane Tartag and Gen. Mohamed Mediene, who was known Toufik — a name that once made Algerians tremble.
They were convicted of plotting against the state and undermining the army in the early weeks of the protests against Bouteflika, who was seeking a fifth mandate despite infirmities following a stroke.
The charges centered on March meetings between the three men and Hanoune, leader of the left-wing Workers Party. Some feared they were plotting to fire powerful army chief Ahmed Gaid Salah, who at the time was siding with the protesters.
However, the daily El Watan quoted lawyers as saying the meetings centered on finding someone to head a transition period without Bouteflika. Lahcene Seriak, the lawyer for Toufik, a general who headed the powerful DRS intelligence service and forced into retirement in 2015, said his client told the court on Tuesday that "the real plot that put me in court today grew from my attempts to fight corruption," notably against the Bouteflika clan.
The four were arrested in May, after Bouteflika was forced out amid anger at rampant corruption, unemployment and lack of political freedom. The pro-democracy demonstrations have continued ever since.
The trial was chaotic. Said Bouteflika refused to answer the judge's questions and walked out, according to one of the lawyers present. Tartag, who worked directly under the president, refused to leave his cell. Neither was present for the verdict.
The army chief used his claims of a vast conspiracy to press for a new presidential election, which is now scheduled for Dec. 12.