People hold a gaint flag with the national colors of Brazil during a protest against corruption at Copacabana beach, in Rio de Janeiro, Brazil. (Silvia Izquierdo/AP)

Brazil’s Supreme Court has authorized an investigation of over 100 top politicians, implicating an entire swath of the country’s governing elite in a corruption probe that has tarnished the political system and threatened to derail the nation’s economic recovery.

Nearly a third of the president’s cabinet, the heads of both chambers of Congress, two dozen senators and 42 representatives will be investigated for corruption, money laundering and fraud, according to a list released late Tuesday by a Supreme Court justice presiding over the cases. Five former presidents were also implicated. The list was the subject of rumors and leaks for weeks and sent shock waves through the capital when it was made public.

“It’s a bomb,” said political analyst Lucas de Aragão of the Brasilia-based consulting firm Arko. “But at least the investigations will bring more predictability to the political context, as we learn the size of the pickle each politician finds himself in.”

The investigations are the product of testimony delivered in March by former executives of the Odebrecht Construction Group, a company at the center of a $2 billion corruption scheme that has been front-page news in Brazil for three years. Through what’s known as the “Car Wash” scandal, Brazil’s largest construction firms paid bribes in exchange for looser regulations, political favors and help in winning bids on government projects.

A series of plea deals with people under investigation in the probe has allowed Brazil’s justice department to trace the scandal from the smallest of operatives to the highest levels of government, uncovering the largest corruption scheme in the country’s history.

Brazil’s President Michel Temer looks down during a ceremony at the Planalto Palace, in Brasilia, on April 12. (Ueslei Marcelino/Reuters)

Prosecutors will now investigate the 108 people listed and decide whether to press charges or drop the cases. Although President Michel Temer was not listed, the investigation could wipe out the most powerful members of his entourage and leave his economic agenda in tatters.

The president’s chief of staff, foreign minister, trade minister and agriculture minister are among those under investigation. Former presidents Luiz Inácio Lula da Silva, known as “Lula”; Dilma Rousseff; Fernando Henrique Cardoso; Jose Sarney and Fernando Collor de Mello were also cited in the list.

The widely unpopular Temer government has been plagued by scandals since he took office following Rousseff’s impeachment in August. The current president is trying to pass tough austerity measures that he hopes will revive the country’s economy, which is going through its worst recession on record.

But whether the show can go on with nearly a third of the cabinet and Senate under investigation remains to be seen. The probe could shrink the president’s base of support in Congress, as his allies are plucked away one by one.

“We must never paralyze legislative activity,” Temer said at a news conference after the list was released. “We must continue with the legislative and judicial acts of governing.”

Temer has shrugged off approval ratings that hover at 10 percent, arguing that his lack of political ambition in the next election cycle makes him the right person to pass difficult reforms to the country’s pension system, labor laws and tax code.

But the investigation may put him at odds with allies in Congress implicated in the scandal. As sitting members of government, the congressmen benefit from a rule known as the “privileged forum” that gives them the right to be tried by the Supreme Court, which has been historically more lenient than the lower courts. Maintaining their seats in the coming elections may be a matter of legal life or death for these politicians, and austerity reforms are a tough sell.

Just hours after the investigations were announced, the vice president of the lower house of Congress called for a suspension of Temer’s pension plan, saying that this was “a very bad time to try and pass any kind of reform.”

If he can maintain his support in Congress, however, the president may be able to squeeze through reforms before leaving office in 2018. Analysts estimate that it could take up to two years for the investigations to lead to charges.

“He is playing a battle against time,” said Marcus Melo, a political-science professor at the University of Pernambuco in Recife. “We are seeing radical changes and impunity has been drastically reduced, but it still takes extremely long to convict someone.”

All five of Brazil’s living former presidents were listed as being implicated in the Car Wash scandal, but only Collor de Mello, who served as president from 1990 to 1992 and is currently a senator, will be investigated through the Supreme Court. He is accused by two executives of receiving illicit campaign funds. He has declined to comment on the accusations. Lower courts will decide whether to investigate the other four presidents: Rousseff; Lula, who was in office from 2003 to 2011 ; Cardoso, who was president from 1995 to 2003 , and Sarney, who was in office from 1985 to 1990.

The scope of the investigations will have implications for the 2018 elections. Nearly all of Brazil’s likely candidates for president in 2018 are tied to the scandal in one way or another, leaving the door open for an outsider to sweep up votes.

This possibility has not been lost on João Doria, a businessman who rode the country’s frustration with politicians to victory in the São Paulo mayor’s race in 2016. Doria said in a statement that the Supreme Court investigations are “fraying” Brazil’s political establishment. Doria, or another outsider, may be able to parlay the crisis into support from an established party in search of a clean candidate in 2018.