WASHINGTON (Reuters) - A battle over who should run the U.S. Consumer Financial Protection Bureau (CFPB) in the coming months was set for court as Obama-era holdovers sought to maintain their control over a powerful watchdog which President Donald Trump is seeking to curb.

File Photo - Office of Management and Budget Director Mick Mulvaney waits to testify before a Senate Budget Committee hearing on FY2018 Budget Proposals on Capitol Hill in Washington, U.S., May 25, 2017. REUTERS/Yuri Gripas

CFPB staff returning to work on Monday after the U.S. Thanksgiving holiday break were left scratching their heads over who was in charge after outgoing director Richard Cordray formally resigned on Friday and elevated his former chief of staff, Leandra English, to replace him temporarily.

Hours later, President Donald Trump sought to over-rule that move by naming his budget chief Mick Mulvaney -- a harsh critic of the agency -- as acting director. Trump wants Mulvaney to run the CFPB until he can get a permanent successor confirmed by the Senate, a process which could take months.

In yet another twist late on Sunday, English sued the Trump administration seeking to block Mulvaney’s appointment. The move means a federal court will now decide which law applies when filling a temporary leadership vacancy at the relatively new agency.

The unprecedented battle reflects competing visions of how to regulate the U.S. financial system.

Created in the wake of the financial crisis to protect consumers from predatory lending, the CFPB is hated by Republicans who think it wields too much power and burdens banks and other lenders with unnecessary red tape.

President Barack Obama appointed Cordray, a Democrat, as the CFPB's first director and he developed a reputation for drafting aggressive rules curbing products such as payday loans while issuing multimillion dollar fines against large financial institutions like Wells Fargo WFC.N.

In a tweet over the weekend, Trump called the agency a “total disaster” that had “devastated” financial institutions. He has pledged to roll back many of the Obama-era financial regulations.

Liberal groups and consumer advocates planned a rally in front of the CFPB headquarters on Monday morning to demonstrate support for the agency.

AN AGENCY IN LIMBO

As acting director, Mulvaney would have the power to make far-reaching decisions on enforcement and supervision of financial firms.

Trump administration officials say the president has the power to appoint an acting director under the 1998 Federal Vacancies Reform Act and, in an powerful boost for them, the CFPB’s own general counsel, Mary McLeod, issued a three-page memo agreeing.

“I advise all Bureau personnel to act consistently with the understanding that Director Mulvaney is the Acting Director of the CFPB,” McLeod’s memo, dated November 25, stated.

Such advice will stick in the throats of many CFPB staffers. Mulvaney once described the agency as a “sad, sick joke” and tried to get rid of it when he was a lawmaker in the House of Representatives.

English alluded to Mulvaney’s views on the CFPB in her lawsuit. She has argued that the 2010 Dodd-Frank Wall Street reform law that created the CFPB stipulated that its deputy director would take over on an interim basis when a director departs. Cordray named English as deputy director and said she would become the acting director.

The CFPB was the brainchild of Elizabeth Warren, a Democratic senator and liberal firebrand. Over the weekend, lawmakers from both parties lined up to give opposing views of its role.

Dick Durbin, the U.S. Senate’s No. 2 Democrat, told CNN on Sunday that “Wall Street hates it like the devil hates holy water.”

While the legal battle rages, the CFPB’s enforcement work will be put in limbo.

“Anything that the agency does or fails to do could be subject to challenge until this cloud is removed,” said Harvard Law School professor Laurence Tribe.

The CFPB was preparing to sue Santander SAN.MC as early as this week alleging that the Spanish bank overcharged borrowers on auto loans, two sources familiar with the plans told Reuters last week.

It was not clear if that lawsuit will now go ahead.

The agency’s rule-making ability has already been halted by the Republican-controlled Congress, which last month killed a CFPB rule that had allowed borrowers to join together to sue lenders.

Even if English prevails, Trump’s permanent nominee is expected to neutralize much of the CFPB’s work. Some of the names mentioned by lobbyists as potential permanent successors to Cordray include Republican Representatives Jeb Hensarling and French Hill, both CFPB critics.