Brazil's justice minister has resigned amid a firestorm in the ruling Workers' Party over his failure to curb a corruption probe that has targeted prominent figures including the country's popular former president, Luiz Inacio Lula da Silva.

Jose Eduardo Cardozo, who had served as justice minister since 2011, will be replaced by Wellington César Lima e Silva, a prosecutor from the state of Bahia linked to the Workers' Party, President Dilma Rousseff's office said in a statement on Monday.

His resignation came amid growing discontent within the party over a wide-reaching bribery and kickbacks investigation that landed some of its officials in jail and has now spread to include its founder, Lula.

Brazilian dailies Folha de S.Paulo and Estado de S.Paulo said the pressure on Cardozo increased in recent days after Lula, who was president from 2003-2010, was notified that courts were planning to subpoena his bank, telephone and financial records.

Cardozo will replace outgoing Attorney General Luís Inácio Adams and take over responsibility of defending the Rousseff government as it faces increasing scrutiny over the alleged funding of her 2014 re-election campaign with graft money.

Brazil has been rocked by a massive price-fixing, bribery and kickbacks investigation tied to state-led oil company Petroleo Brasileiro SA that has ensnared members of its political and business establishment.

Lula has already faced police questioning over the financial dealings of his children and friends and now faces questioning of his alleged ownership of a beach-front penthouse triplex and country estate.

The penthouse and country home were allegedly renovated by construction companies involved in the scandal at Petrobras, as the state oil firm is commonly known. Lula has said the properties don't belong to him.

On Saturday, Lula lashed out over the subpoenas.

"If this is the price people must pay to prove their innocence, I'll do it," Lula said referring to the subpoenas.

"The only thing I want is that afterward they give me a good conduct certificate, because I doubt there is anyone more honest than I am in the country."

Party Pressure

Cardozo, a lawyer and professor who is recovering from lymphatic cancer, was upset over Workers' Party pressure on him to hold back what some saw as a political witch hunt against Lula and other government allies. He has said he has no authority to interfere in investigations without evidence that police violated a person's rights.

Brazilian President Dilma Rousseff gestures during a meeting with representatives of the National Council of Christian Churches of Brazil (CONIC) at the Planalto Palace in Brasilia, Feb. 10, 2016.

The cabinet changes followed last week's arrest of Joao Santana, a political consultant who ran Rousseff's two successful presidential bids and Lula's successful re-election campaign in 2006.

Prosecutors allege Santana was paid with money siphoned from Petrobras by corrupt construction companies who bribed the oil firm's executives and politicians in Rousseff's governing coalition.

If prosecutors turn up evidence Rousseff's 2014 campaign was funded with illegal money, that would boost a case brought by the main opposition party, the PSDB, asking the top electoral court to annul her re-election.

Rousseff, whose popularity has tumbled in the midst of Brazil's worst recession in decades and the corruption scandal, is also facing a bid in Congress to impeach her for allegedly manipulating government accounts in 2014 so as to allow more public spending in the run-up to the elections.