BUFFALO, Wyo. — The U.S. government has publicly and privately pressured countries that act as offshore havens for hiding money, while this barren, sparsely populated state offers the same secrecy.

The Cowboy State isn’t as notorious as the Cayman Islands for cloaking millions. But, like Nevada and Delaware, this unlikely haven offers the same anonymity the federal government has been trying to end abroad. America and Americans are part of the offshore problem.

A massive leak of documents from the global law firm Mossack Fonseca & Co., which has offices in Wyoming and Nevada, exposes how two Western U.S. states are tied to foreign scandals, and how middlemen in far-flung places are taking advantage of the anonymity they provide.

Through this law firm, Wyoming, a state that has twice as many head of cattle as it has people, and Nevada, a state known to embrace a gamble, are tied to a scandal that threatens the government in Brazil, and to Russian middlemen who establish paper-thin companies called shells for the wealthy.

Wyoming?

Wyoming had 128,000 active business entities at the end of 2015, roughly one entity per every 4.5 residents in a state.

U.S. law allows foreigners to create shell companies that have no revenue or actual business activity in the United States. It’s akin to what foreign offshore tax havens offer Americans, some of whom use them as a tax dodge, or worse.

“There is no question that the United States serves as one of the biggest tax havens in the world for people outside the United States,” said Daniel Reeves, now a consultant after retiring three years ago from the Internal Revenue Service, where he helped create its offshore compliance program.

Wyoming and its competitors do not distinguish between foreigners and Americans who open businesses. Anonymity is a selling point.

State officials prefer the word “privacy,” and say they insist a living, breathing contact is required for every entity created.

Because of that, said Deputy Secretary of State Karen Wheeler, Wyoming statutes “don’t ask for information such as, ‘Are you from a foreign country?'”

Nevada shell company Murray Holdings LLC became a centerpiece in Brazil’s political crisis, which now threatens to overshadow this summer’s Olympic Games. Prosecutors there allege the Nevada firm had no assets or business in the United States, yet was used to hide embezzled funds from Brazil’s state oil company, which was then funneled into real estate.

Murray Holdings is found in a trove of Mossack Fonseca documents analyzed by The McClatchy Company that shows how foreign nationals establish U.S. shell companies to camouflage assets or money abroad.

Known by the initials MF, for Panamanian founders Jurgen Mossack and Ramon Fonseca, the law firm offers customers everything from simple preparation of incorporation documents almost anywhere in the world to supplying – on paper at least – managers, shareholders and corporate directors for shell companies.

For an added price, the firm will create a website, a virtual office and a call center to mimic a brick-and-mortar company.

What emerges from the 11.5 million secret emails, PDFs, spreadsheets and other electronic records are actors of every imaginable profession using shells to hide money and assets. Some of the firm’s clients have criminal records; some are known to have accumulated spoils from corruption.

There’s nothing inherently illegal with forming a limited liability company most anywhere – and Wyoming now has about 70,000. Often called an LLC or Ltd, the designation limits the owners’ liability to what they have invested in their company. Similar entities abound abroad.

When Americans open an LLC in the United States, they provide a Social Security or taxpayer ID number. It’s a murkier picture when foreigners open U.S. shells.

Having tax haven states is at odds with the U.S. multiyear crackdown on Swiss banks that hide American money. It also stands out against “name and shame” efforts by the State Department, which lists money-laundering centers such as the Cayman Islands when it publishes an annual narcotics-control report.

Here’s how Nevada and Wyoming fit into scandal in faraway Brazil. Former President Luiz Inacio Lula da Silva was hauled in for questioning by that country’s Federal Police on March 4 as part of an investigation into money stolen from state-owned oil giant, Petrobras.

Prosecutors told judges that stolen money first flowed through shell companies in Nevada and was then used to anonymously buy seaside real estate in Guaruja, a resort town in the state of Sao Paulo where the former president has a condo.