Republican U.S. presidential nominee Donald Trump shakes hands with Democratic U.S. presidential nominee Donald Trump and Hillary Clinton both have wealthy Wall Streeters on their shortlists for possible White House jobs. REUTERS/Mike Segar

For Wall Street titans, there are many obvious reasons to take a spin through the revolving door and into a job in a presidential administration. There is the promise of wielding executive power, the possibility of legislative influence and the prospect of personal fame. Thanks to a special clause in the tax code, there is also one other attractive enticement: a tax break that can help moguls defer millions of dollars they would otherwise owe in taxes.

During the 2016 campaign, Clinton and Trump raised millions from corporate executives — and Wall Street icons have been mentioned as possible Cabinet members for either candidate’s administration. If they do get appointed, a provision buried in the tax code would allow them to defer any capital gains tax they would have to pay if and when they sell off their personal investments upon taking a government job. With the stock market near a high point, that provision could save appointees tens of millions of dollars in taxes they would normally have to pay when selling off their holdings.

“Knowing how people of that caliber think about taxes, this is going to be a very important provision more important than ever before,” said Robert Willens, a former Managing Director at Lehman Brothers who specializes in tax planning for high-net worth individuals. “This would become a very important part of the pitch to attract them to government.”

The provision in question was designed to help mitigate the personal financial impact of Watergate-era ethics laws requiring appointees to terminate investments that could present a conflict of interest. During the George H.W. Bush presidency, Congress added language to the tax code allowing appointees who sell off assets to reinvest the gains in government bonds or other low-risk securities and postpone capital gains taxes.

In 2006, the tax provision briefly made headlines when Goldman Sachs CEO Henry Paulson was nominated as Treasury Secretary, providing him the chance for a tax deferment of up to $48 million. The situation spotlighted how valuable the provision can be to high net-worth individuals. By creating a tax-free conduit for magnates to shift their varied holdings into less volatile investments during a market upsurge, the provision provides a lucrative financial planning tool — one available to a select few, and with no limit on how much can be deferred.

“The benefit is potentially large,” said Steven M. Rosenthal, a senior fellow in the Urban-Brookings Tax Policy Center. “The reason the provision is in the code is to accommodate the concerns of wealthy people who might be disinclined to take a government position that would oppose a tax hit.”

Speculation about who would be Clinton’s Treasury Secretary has revolved around Blackstone president Tony James; BlackRock CEO Larry Fink and Facebook COO Sheryl Sandberg. Those executives presumably have holdings in their own companies, which could position them to reap a financial benefit from a Clinton administration job. If they get a government appointment, the tax provision would allow them to diversify their holdings while deferring the capital gains taxes that would normally be owed on such a transaction.

“Trump too has floated the possibility of appointing high-net worth individuals with potential conflicts of interest to government posts. The billionaire investor Carl Icahn, who has financial stakes in a dizzying array of companies, from Xerox to the vitamin manufacturer Herbalife— is considered to be a top contender for Trump’s Treasury Secretary. Trump’s finance chair Steven Mnuchin is also being considered for the Treasury Secretary job. A former Goldman Sachs banker, he now heads the Hedge Fund Dune Capital.

“If you want to convert a substantially appreciated asset into a diversified asset portfolio without paying capital gains tax, choose your favorite Presidential candidate with extra care, attorney John Wagner wrote. “He or she could save you a lot of tax by giving you a job.”

In recent years, some Democrats — including Clinton — have backed legislation to restrict companies from giving special bonuses to their executives if they get a presidential appointment. The bill was introduced after documents emerged showing that Treasury Secretary Jack Lew had a contract with Citigroup that promised him a payout if he secured a government job. The legislation, however, does not address the separate capital gains tax benefit.

Under federal law, executive branch appointees are required to obtain a certificate of divestiture in cases in which they believe it's “reasonably necessary to avoid possible conflicts.” The request can be made on simple two-page form, and the certificate allows them to get the capital gains tax deferment on their annual IRS forms. In the last two administrations, hundreds officials have sought certificates of divestitures, according to the Office of Government Ethics.