“We thought it was a good solution to the problem,” he said. “Here was a place willing to take on the risk of banking this underbanked group — and that could do rigorous compliance.”

The credit union’s lawsuit could push the courts to resolve the continuing conflict between the federal laws against marijuana and the dozens of states that have legalized it in some form.

Peter Conti-Brown, a professor of legal studies at the University of Pennsylvania’s Wharton School, said there was little precedent to guide the courts in such a case. Still, he said, it will be an uphill battle for the credit union to prove that the Fed does not have the power to turn down the institution.

“Most of the cards are in the Fed’s hand,” he said.

This year, the president of the Kansas City Fed, Esther George, wrote that the Fed had “discretion” in deciding which master accounts to open. She also said the Fed would consider the decision made by the National Credit Union Administration on whether to grant the Denver credit union deposit insurance, similar to the $250,000 coverage that the Federal Deposit Insurance Corporation provides for standard bank accounts.

Shortly before the Fed made its decision this month, the credit union administration, an independent federal agency, privately informed the Fourth Corner Credit Union that it was not eligible for insurance, partly because it had not proved how it would “mitigate the risk associated with serving a single industry that does not have an established track record of success and remains illegal at the federal level.”