As the mayor of New York, Mike Bloomberg often jumped to defend Wall Street and rebut calls for tough banking industry regulations after the global financial crisis.

On Tuesday, Bloomberg, who is running for president in the Democratic primary, announced an extensive proposal that appears to reverse many of his former positions. It would reinstate tougher oversight for giant banks, institute a financial transactions tax and strengthen consumer protection laws.

Among other things, the plan would also make it easier for the Justice Department to prosecute bankers for violations of the law.

Bloomberg released the plan just a day before he was scheduled to confront his Democratic rivals on the debate stage for the first time. He is likely to be asked about whether he has been too cozy with Wall Street in the past. He has faced backlash for a past interview in which he blamed the 2008 financial crisis on politicians who had pushed to end racially discriminatory mortgage-lending policies known as “redlining.”

Bloomberg’s proposal would take on some of the biggest customers of his namesake financial data company, including Goldman Sachs and JPMorgan Chase as well as hedge funds and high-frequency traders.

Many of the proposals are similar to those of his most liberal Democratic rivals. Sen. Elizabeth Warren (Mass.), for example, introduced a plan last year to make it easier to lock up corporate CEOs. But he doesn’t go as far as Warren and Sen. Bernie Sanders (I-Vt) in some areas, such as a wealth tax on the richest Americans.

Wall Street has been a frequent target of the Democratic presidential candidates, and Bloomberg’s long-standing deep connections to the industry have been viewed as a potential weak point in his campaign.

One of the measures most likely to worry Wall Street is Bloomberg’s proposal to create a financial transaction tax of 0.1 percent for every stock or bond traded. It would be phased in, starting at 0.02 percent, according to the proposal. Sanders and Rep. Alexandria Ocasio-Cortez (D-N.Y.) have supported legislation that would impose a similar tax. Warren has proposed using a financial transaction tax to help pay for her health-care plan.

Bloomberg previously had objected to a financial transaction tax, concerned that if the United States imposed such a fee, the financial industry would migrate overseas, said Stu Loeser, a senior adviser to the Bloomberg campaign. But since then, several countries, including Britain and Hong Kong, have imposed similar taxes, he said. “Their experience shows the markets can flourish with [a tax,] and that takes care of our concern of America being the only one," Loeser said.

“The world has changed since the financial crisis. It has changed in lots of ways, including the need for greater efforts to combat inequality," he said.

The proposed tax would be particularly costly for high-frequency traders who can trade thousands of shares of stock in fractions of a second. Wall Street has been preparing to fight such proposals, arguing that such a tax would also be costly for retirement savers and pension funds. “Ultimately, this is not just a tax on the wealthy but all Americans invested in the markets, whether it is 401(k) holders or pension fund recipients,” said Kirsten Wegner, chief executive of Modern Markets Initiative, a financial industry advisory group.

Bloomberg, who has spent more than $300 million on his presidential campaign, got his start on Wall Street at Salomon Brothers before starting his financial data company. As mayor of New York, he often came to the industry’s defense. After a former Goldman Sachs employee wrote a scathing New York Times op-ed calling the corporate environment “toxic and destructive,” Bloomberg reportedly visited the bank’s headquarters the next day in support of employees. “Goldman Sachs is a firm that’s been around for well over 100 years, and it’s a great firm," he said during a radio interview.

Before the financial crisis, Bloomberg argued at a 2006 conference that Wall Street was already overly regulated, recalled former congressman Barney Frank (D-Mass.), one of the chief sponsors of the financial reform bill known as the Dodd-Frank Act. After the crisis, he continued to object to new regulations, Frank said. “I think he was still a Republican back then,” he said. “The financial industry is one of the top employers and revenue generators in New York, and he was acting like any local representative protecting his moneymaker.”

In a 2010 letter to Rep. Carolyn B. Maloney (D-N.Y.), Bloomberg warned about taking “punitive actions” against the industry. “The world adjusts to stupid laws,” he said in 2014 before the Securities Industry and Financial Markets Association, one of Wall Street’s biggest lobbying groups. “They just don’t pay attention to it, and you get burned later on. That really is what happens, like a 25-mile-an-hour speed limit.”

The New Yorker’s change of heart is probably a reflection of political reality, and his previous positions should not be disqualifying, Frank said. “I am very pleased that he has decided to come around,” he said.

Bloomberg is proposing to reinstate the toughest parts of the law that have been weakened during the Trump administration. Regulators, for example, have rolled back the “Volcker rule,” which blocked some of the riskiest types of trading, and requirements for corporate “living wills,” plans for large companies’ closure during another economic crisis.

Bloomberg’s plan would reverse those rollbacks and others. It also calls for strengthening periodic stress tests in which regulators gauge whether big banks could survive another financial calamity, and creating a bipartisan commission to recommend ways to make the financial system more efficient.

“Given how profoundly the 2008 crisis undermined faith in the establishment — and given how close it brought the world to economic collapse — authorities everywhere should be doing all in their power to fix the flaws it revealed,” Bloomberg’s plan says.

Bloomberg’s proposal also calls for strengthening the Consumer Financial Protection Bureau, the brainchild of one of his Democratic primary rivals, Warren. During the Trump administration, the bureau has rolled back regulations of payday lenders and dropped lawsuits against the industry. It has also dismantled a unit dedicated to prosecuting violations of fair-lending laws.

Under Bloomberg’s proposal, tough payday industry regulations would be put back in place, and the bureau’s powers would be extended to include regulation of auto lending and the credit reporting agencies.

“At first blush, Bloomberg’s proposal seems tough for someone who has made his fortune from the financial services industry,” Ian Katz, an analyst at Capital Alpha Partners, a policy and political research company in Washington, wrote in a note Tuesday. “But he’s running for the Democratic presidential nomination, not to win more friends on Wall Street.”

Even if Bloomberg were to become president, many of his proposals would require the cooperation of Congress and the help of regulators, Katz said. “Many would surely be ditched or watered down,” he said.