Montana's Democratic governor and the state's Revenue Department filed a federal lawsuit Tuesday against the Internal Revenue Service and the Treasury Department over a recent policy change allowing some tax-exempt groups to keep the identities of their donors secret from federal tax authorities.

Gov. Steve Bullock announced the lawsuit in a video posted on his Twitter account.

"I’ve been working for 10 years to make sure that corporations can’t control our elections," Bullock said in the video. "Just last week, the Secretary of the Treasury made it so that corporations, foreign interests, anybody can give to dark money groups and the IRS wouldn’t even collect their names. I think Americans certainly deserve better."

In the lawsuit, Bullock and the Revenue Department argue the policy change should be overturned because it was made without taking public comment and hurts states' abilities to determine whether organizations should be given tax-exempt status because states rely on data from the IRS. They also argue that the change would allow organizations to take unlimited corporate, or even foreign, contributions to influence elections.

"If the IRS knows that an organization is engaged in political activity and receives a disclosure that the organization's only significant contributors are foreign nationals, then the IRS is well-positioned to identify and stop a serious violation of federal law," the lawsuit argues.

The IRS doesn't need the donor information to effectively enforce tax law and can request it in the case of an audit, Treasury Secretary Steven Mnuchin said last week.

Neither the IRS nor the Treasury Department had any immediate comment Tuesday.

Attorney General Tim Fox, the state's chief legal adviser and a Republican, wasn't aware of the lawsuit.

"The attorney general first learned about the lawsuit on Twitter," spokesman Eric Sell said. "Governor Bullock's office only contacted us once the lawsuit was filed. Since the state's chief legal officer was not consulted prior to the filing, this looks like a political stunt by someone not focused on the job he currently occupies."

This is not the first time Bullock has fought against so-called "dark money" in elections. As attorney general, he defended the state's Copper Kings-era law that restricted direct spending by corporations on candidates and political committees, but lost when the U.S. Supreme Court applied state elections to its 2010 Citizens United decision allowing corporate spending.

In 2015, as governor, he pushed through the Disclose Act, a law that updated the state's campaign finance rules to require more disclosure and additional filing by candidates and political committees. The law has so far withstood multiple legal challenges that argue it runs counter to Citizens United.

Tuesday's lawsuit is the third time in recent months that Bullock has inserted himself and Montana into national issues and continues his efforts in support of transparent elections.

In January and June, Bullock signed executive orders requiring companies with state contracts to abide by net neutrality rules and to report their political contributions, even disclosures that aren't required under federal law.

Bullock is believed to be considering a run for the presidency in 2020 and is scheduled to visit the first-in-the-nation primary state of New Hampshire next month to support local Democratic candidates.

The Associated Press contributed to this report.