The United States government is close to issuing a rule that will for the first time require banks and other financial institutions to find out the identities of people hidden behind shell companies.

The rule is meant to close a major loophole in the American banking system that enables the sorts of secretive financial maneuvers that were thrust into the spotlight this week with the leak of millions of documents from a law firm in Panama.

That firm, Mossack Fonseca, is one of the largest incorporators of shell companies in the world. The trove of leaked documents — analyzed by more than 100 news organizations worldwide — revealed offshore companies tied to 143 politicians, their families and close associates.

The documents also showed scores of shell companies doing business with major international banks, including UBS, Credit Suisse and HSBC, that rely on access to the American banking system.