WASHINGTON – The nation's consumer watchdog for credit cards, mortgages and other financial products is set to emerge from a legal cloud that threatened its authority after a Senate deal paved the way for confirmation of its director.

After Tuesday's approval of Richard Cordray to a five-year term as the head of the Consumer Financial Protection Bureau, the young agency now has the certainty that it has lacked since being created as the centerpiece of the 2010 Wall Street reform law.

That means that bureau rules and enforcement actions designed to protect consumers from risky mortgages, misleading credit card marketing, abusive debt collection and other questionable financial practices won't be in danger of being overturned because of legal questions about Cordray's controversial recess appointment in 2012.

"It finally removes the cloud that's been hanging over the agency since he got appointed a year and a half ago," said Alan Kaplinsky, chair of the consumer financial services group at law firm Ballard Spahr.

The financial reform law gave the bureau authority over a wide range of financial products and services, including debt collection, payday loans and others that have mostly eluded federal regulation.

Nearly all congressional Republicans and much of the financial industry opposed the bureau as a government overreaction, and they fought hard to reduce its power. They demanded changes in the bureau's structure, including replacing the single director with a bipartisan board, that the White House and Senate Democrats opposed.

"The lack of accountability and congressional oversight over the bureau's budget and director is troubling to say the least," Sen. Mike Enzi, R-Wyo., said.

As leverage to get their way, opponents blocked a confirmation vote on Cordray, a former Ohio attorney general. He was nominated by President Obama two years ago and installed in January 2012 with a recess appointment that was at risk of being overturned by the Supreme Court.

Such a ruling could have left the bureau without a director and without tough regulations that required a director's approval, including the levying of nearly $500 million in fines against banks and financial services companies.

But on Tuesday, Cordray cleared a major procedural hurdle after Democrats and Republicans reached a tentative agreement to avoid a confrontation over the use of filibusters on presidential nominees.

The Senate then voted 66-34 to confirm him. His recess appointment would have expired at the end of this year.

"Now … there's no doubt that the consumer agency will survive beyond the crib," said Sen. Elizabeth Warren, D-Mass., who helped create and launch the agency before being elected last year. "There is now no doubt the American people will have a strong watchdog in Washington."

Cordray's confirmation removes questions about his future, said Scott Talbott, the chief lobbyist for the Financial Services Roundtable, which represents large banks. The trade group would prefer that a five-person board run the bureau, but Cordray has been a "solid" director, Talbott said.

"He is a thoughtful and careful leader," Talbott said. "While we don't always agree, he has an open door and will sit down and hear your side of the issue."