Former Brazilian President Luiz Inacio Lula da Silva arrives at Federal Justice for a testimony in Curitiba, Brazil, May 10, 2017.
CURITIBA, Brazil - Brazil's leftist former president Luiz Inacio Lula da Silva testified Wednesday in his corruption trial, part of a mammoth graft probe shaking the country ahead of elections next year.
Arguably the country's most popular and controversial politician, Lula is accused of receiving a seaside apartment as a kickback from the OAS construction company.
He was grilled in the southern city of Curitiba by Judge Sergio Moro, head of the "Car Wash" graft probe, which has already upended Brazilian politics.
The hearing was closed to the public and media. Hundreds of riot police ringed the courthouse, with police marksmen stationed on rooftops.
A guilty verdict and failure of an appeal in this -- or four other pending corruption trials -- would bar Lula from seeking political office again.
Lula, who was president from 2003-2010 and is seen as a frontrunner to return to power in 2018, could also be sentenced to prison.
Thousands of supporters, many dressed in the red of Lula's Workers' Party, bussed into Curitiba to protest against what they see as a judiciary out to sabotage his comeback.
Skilled at political stagecraft, Lula stopped on his way to the courthouse, wearing a tie in the colors of the Brazilian flag, to wade into the sea of backers.
"Lula, warrior of the Brazilian people," they chanted.
"I think he is innocent. If they had something concrete against him, there's no doubt he'd have been arrested," said supporter Gerson Castellano, 50. "It's a class struggle that's going on."
A much smaller group of opponents also gathered, raising an inflatable caricature of Lula dressed in prison garb.
A verdict is not expected for several weeks.
Brazil's media talked up the court session as a showdown between two of the most powerful men in Brazil.
Lula is a giant of the left. Moro, 44, has become a hero for many by going after the rich and powerful, ranging from billionaires to senators.
The "Car Wash" probe has revealed massive kickbacks and embezzlement from state oil company Petrobras at the heart of the Brazilian elite, much of it during Lula's 2003-2010 presidency.
In Wednesday's case, Lula is alleged to have taken a bribe from OAS in the form of a luxury seaside apartment near Sao Paulo, which did lucrative business with Petrobras.
Prosecutors say they suspect he not only took bribes and sold influence, but amounted to a kingpin over the wider scheme.
Lula vigorously denies the charges, describing the onslaught as an attempt to destroy him and his leftist movement.
Hashtags trending on Twitter reflected the buzz and the bitter divide across Brazil, including #LulaEuConfio (I trust in Lula) and #MoroOrgulhoBrasileiro (Moro, pride of Brazil). Even more basic were #BrasilComLula (Brazil with Lula) and #BrasilComMoro (Brazil with Moro).
Raising pressure on Lula, a judge in Brasilia on Tuesday ordered the suspension of activities by the Lula Institute, a social research body set up by the ex-president, over suspicions it was linked to criminal activity in a separate corruption case.
President Michel Temer, a hugely unpopular figure who took over when Lula's successor Dilma Rousseff was impeached and removed from the presidency last year, appealed for calm.
"We need to calm down the country. The country can't be in this permanent state of conflict, with Brazilian against Brazilian," he said.