Securities and Exchange Commission Chairman Mary L. Schapiro said Thursday that, in hindsight, former general counsel David M. Becker, who inherited part of a Bernard Madoff investment account, should have stayed out of the agency’s work on the Madoff bankruptcy.

Responding to criticism that she mismanaged a conflict of interest by allowing Becker to participate in the matter, Shapiro testified that she relied on Becker, an experienced lawyer, to handle any ethical issues after he told her about the account in 2009.

“Do I wish now that he had been more sensitive to the potential of this issue to raise an appearance of a conflict? Yes, I wish it hadn’t happened,” Shapiro said.

“I wish that Mr. Becker had recused himself, absolutely,” she added.

Schapiro appeared on Capitol Hill on Thursday to testify on the Madoff affair for the first time since Becker’s inheritance came to light and engulfed her in controversy.

Lawmakers, especially Republicans, were waiting to grill her on the issue at a hearing convened by two subcommittees of the House Committee on Oversight and Government Reform.

A pair of banners behind the dais telegraphed their message: “Can American taxpayers trust today’s SEC to manage itself and do its job?” and “Is Wall Street’s watchdog competent and impartial?”

Oversight Committee Chairman Darrell Issa (R-Calif.) said the Becker affair “could be the greatest challenge to the SEC’s credibility since Bernie Madoff managed to dupe so many Americans, steal so much money with his Ponzi scheme, and escape the proper scrutiny of the SEC for so long.”

The committee’s ranking Democrat, Rep. Elijah E. Cummings (Md.), said he, too, was troubled by the matter. Cummings said it left every decision Becker made suspect.

Schapiro promised the SEC would learn from the experience.

“I’ve worked so hard the last two years to try to put this agency back on the right path and to earn the trust of the public, and you’re right, a small thing like this, not so small thing . . . can really set us back, and it’s not fair to 3,800 hardworking employees,” she said.

Becker was invited to testify at the hearing but declined because his family had previously scheduled a trip, an attorney for Becker said Wednesday.

When Becker’s mother died in 2004, she left him and his brothers a Madoff account with a purported balance of $2 million. The brothers withdrew the money. Later, in 2008, Madoff’s investment business was exposed as a colossal fraud in which some investors had been paid with other investors’ money.

In early 2009, Becker followed Schapiro to the SEC for his second tour of duty as general counsel. He has told congressional investigators that he notified Schapiro about the account.

He also sought advice from an SEC ethics official. That official, who was one of his subordinates, told him that he could participate in the SEC’s response to the Ponzi scheme.

Becker then helped shape SEC arguments as to how much money investors in the Ponzi scheme should be entitled to recoup.

At a time when Schapiro is fighting to secure increased funding for the SEC, she and other agency officials were pressed at multiple hearings Thursday to answer for both the Becker affair and the SEC’s past failure to see through the Madoff fraud despite repeated tips.

Some Democrats complained that no SEC employees were held accountable for the original failure.

SEC officials said disciplinary proceedings are nearing a conclusion. Action ranging from counseling to removal from federal service has been proposed against six employees, officials said. Of 56 employees mentioned by name in an inspector general’s report examining how the agency dealt with Madoff before his fraud collapsed, 35 have left the agency.