This post has been updated.

The end-of-year spending bill deal crafted by congressional leaders Tuesday would dramatically expand the amount of money that wealthy political donors could inject into the national parties, drastically undercutting the 2002 landmark McCain-Feingold campaign finance overhaul.

The language – inserted on page 1,599 of the 1,603-page bill – would allow individuals to give three times the annual cap on national party donations to three additional party committees set up for the purposes of the presidential conventions, building expenses and election recounts.

That means that a donor who gave the maximum $32,400 this year to the Democratic National Committee or Republican National Committee would be able to donate another $291,600 on top of that to the party’s additional arms -- a total of $324,000, ten times the current limit.

In a two-year election cycle, a couple could give $1,296,000 to a party's various accounts.

Advocates for lessening the impact of big money on politics reacted with dismay, saying the move would effectively gut contribution limits.

"This makes the Great Train Robbery look like a petty misdemeanor," said Fred Wertheimer, president of the advocacy group Democracy 21. "These provisions have never been considered by the House or Senate, and were never even publicly mentioned before today.

"Republican and Democratic congressional leaders have entered into a Faustian bargain to return the massive corrupting contributions raised by federal officeholders for the national parties that Congress banned in the Bipartisan Campaign Reform Act of 2002," he added.

Adam Smith, spokesman for the group Every Voice, said in a statement, “Very few people can write checks almost twice the size of the country’s median income, but that’s what this provision will allow. It gives the biggest donors another opportunity to influence politics and buys them more access to politicians.”

Campaign finance experts were taken aback by the scope of the measure, rumors of which first surfaced Tuesday, hours before the deal was finalized. But some said that the expanded contribution limits could significantly bolster the health of the parties at a time when independent super PACs are able to raise unlimited sums.

"The limit is certainly high, but if it has the effect of strengthening the party committees at the expense of the outside groups, I think it is a constructive change," said Kenneth Gross, a Washington campaign finance attorney and former associate general counsel of the Federal Election Commission.

It was not immediately clear who authored the provision. Senate Minority Leader Mitch McConnell (Ky.) had been pushing earlier in negotiations to roll back limits on how much parties could spend in coordination with their candidates.

That measure was not included in the final deal, and McConnell aides said he had not pushed for the expanded giving to separate party committees.

Critics of the measure called on President Obama to reject the spending deal, which is expected to pass in the coming days.

"If the president does sign this bill, he will also own the return of massive corrupting contributions to our national parties and the national scandals that will no doubt follow," Wertheimer said.

The effort to create new avenues for the parties to raise money comes after the Federal Election Commission said in October that donations to convention committees would not count against the annual contribution cap to national parties.

The FEC’s decision came in response to a rare request by the Democratic National Committee and the Republican National Committee, which argued that they needed a new avenue to raise funds for the events after a federal law eliminated public funding for the conventions.

The bipartisan bill, which Obama signed in April, directed $126 million over 10 years that had been allocated to the national political conventions to instead finance pediatric disease research at the National Institutes of Health.

The measure eliminated public funding for conventions that had been available to major national parties since 1976. In 2012, the fund provided each party with about $18 million for the events. Those sums were a small fraction of the amount spent to put on the lavish festivities, however.

Tom Hamburger, Paul Kane and Ed O’Keefe contributed to this report.