“People did this, not the bank,” said Charles M. Elson, a professor and director of the John L. Weinberg Center for Corporate Governance at the University of Delaware. “The behavior was reprehensible and they should have paid the price. But putting the onus on the corporation is a double whammy for shareholders. They were harmed by the actions of management and now they’re paying again.” (As a shareholder himself, Mr. Elson has felt the pain.)

The cost to Wells Fargo of the various scandals and related lawsuits and investigations isn’t limited to the billions it has had to set aside for penalties and other liabilities. The bank has also had to defend itself in regulatory proceedings and various civil lawsuits, including class actions filed by wronged customers, and it has had to conduct multiple internal investigations that revealed even more wrongdoing.

In a windfall for the legal sector, the bank has had to hire a horde of expensive lawyers, consultants and others to handle the fallout, an enormous management task in its own right. Wells Fargo recruited Allen Parker, one of the country’s most highly regarded (and highly paid) banking lawyers — who recently completed his tenure as presiding partner at Cravath, Swaine & Moore, and — as its new general counsel to oversee the sprawling legal problems.

Wells Fargo hasn’t said how much it has spent in legal fees and related expenses, but it has clearly had a material impact on the bank’s results. The costs show up in its efficiency ratio, which is overhead divided by revenue. Wells Fargo has traditionally aimed for between 55 and 59 percent.

At the end of last year, Wells Fargo’s ratio was 76.5 percent.

Stripping out a $3.25 billion charge the bank took in the fourth quarter last year, it was still an elevated 61.5 percent. Wells Fargo’s chief executive, Tim Sloan, called the ratio “completely unacceptable.”

A Deutsche Bank managing director and bank analyst, Matt O’Connor, has been pressing Mr. Sloan at earnings conferences for more clarity on expenses and legal liability, but the bank’s chief executive has resisted. “I’d love to live in a world where I can give you an absolute guarantee and certainty, but it’s just not the world we live in,” he said during an earnings call last year.