If D.C. Mayor Vincent Gray and Jeffrey Thompson had just been hip to the latest wrinkles in shadowy campaign finance, they might not be in trouble today.

Gray unseated incumbent Adrian Fenty in a hard-fought Democratic primary in 2010. Thompson is widely believed to have funded a $653,000 secret campaign on Gray’s behalf. Prosecutors haven’t alleged that Gray knew about the campaign at the time but say that at least some of those working for his election did. Three members of the D.C. Council, including one who supported Gray’s candidacy, have called for his resignation as shoes have continued to drop.

Thompson is the businessman behind D.C. Chartered Health Plan, a managed-care company that has the city’s largest single contract, worth more than $300 million a year. A longtime Gray associate, Jeanne Clarke Harris, said in court last week that “Co-Conspirator #1” — reportedly Thompson — sought to conceal his support for Gray because, if Fenty were reelected, “he did not want the sitting mayor to find out he was supporting his opponent.”

The campaign that Thompson allegedly financed was distinctly old-school. It paid for yard signs, T-shirts and supplies for precinct walkers that were delivered to Gray’s campaign offices (where, presumably, no one asked where they had come from). There was no independent advertising — that would have called attention to the existence of the shadow campaign.

But then, the whole idea of getting in trouble for concealing donations to campaigns is distinctly old-school, too. In federal elections, thanks to some Supreme Court decisions — most notably in the 2010 case Citizens United v. Federal Election Commission — and lower-court holdings, and the eagerness of Republicans in Congress to benefit from such campaigns, concealing donations that dwarf the one Thompson allegedly made is both legal and all the rage.

Playing by the new federal election rules, says veteran campaign finance reformer Fred Wertheimer, Thompson could have hidden his support without fear of legal liability. Funneling equipment to Gray’s campaign would still have been forbidden. But, says Wertheimer, “he could have had someone set up a corporation on his behalf and have it buy advertising in its own name. Corporations don’t have to disclose who gives them money. This would be permitted under Citizens United.”

Or, Wertheimer told me, Thompson could have set up or given his money to a 501(c)4 organization — presumably a “social welfare” organization that is nonetheless permitted to wage political campaigns and does not have to disclose the identity of its donors. Doing just that, Karl Rove’s Crossroads GPS has raised and spent tens of millions of dollars on behalf of Republican candidates.

To be sure, Justice Anthony Kennedy, who wrote the Citizens United decision, expressed hope that donors would disclose their identities. And Republican congressional leaders had supported such disclosures, at least in principle. “We ought to have full disclosure, full disclosure of all of the money that we raise and how it is spent,” Rep. John Boehner, now the House speaker, said on “Meet the Press” in 2007. “We need to have real disclosure,” Republican Senate leader Mitch McConnell told “Meet the Press” in 2000. “What we ought to do is broaden the disclosure . . . . Why could a little disclosure be better than a lot of disclosure?”

But that was oh so then. Now that Republicans are the beneficiaries of secret contributions to groups such as Crossroads GPS, they oppose disclosure. This week, Senate Democrats brought to the floor a bill mandating disclosure of all political donations. They had majority support for the measure, but Republicans, using the cloture requirement for a 60-vote supermajority to consider legislation, blocked the bill from being put to a vote. That wasn’t just some Republicans but all of them, including John McCain, erstwhile campaign finance reformer. McCain is giving situational ethics a bad name.

In defending the right to give and not disclose, Republicans argue that individual and corporate donors should not have to run the risk of offending constituencies and customers who might retaliate by inviting them to fewer parties or ceasing to patronize their products or stores. These donors, in essence, should be held harmless from the negative consequences of their political speech but should be able to benefit from the positive consequences: the changes in policy or government contracts or political access with which they’re rewarded.

Which is exactly what Jeffrey Thompson was allegedly trying to do. If he is brought to trial, he might consider having Boehner and McConnell testify in his defense. A secret mega-donation? What’s wrong with that?