The longtime chief financial officer of the Trump Organization, Allen Weisselberg, was given immunity by federal prosecutors in New York during the course of the Michael Cohen investigation, according to two people with knowledge of the matter.

The news was first reported Friday by The Wall Street Journal.

Weisselberg is "Executive 1" on page 17 of the criminal information filed by prosecutors in the Michael Cohen case, a person with knowledge of the matter told NBC News.

According to prosecutors, Cohen, then Trump's attorney, sent an invoice to Executive 1, meaning Weisselberg, for "Payment for services rendered for the month of January and February, 2017," a payment that was really meant to reimburse Cohen for a payment to Stormy Daniels.

Weisselberg then sent the invoice to another Trump Organization executive via e-mail directing him to "Please pay from the Trust. Post to legal expenses. Put 'retainer for the months of January and February 2017' in the description."

A spokesperson for the U.S. Attorney's Office for the Southern District of New York declined comment.

Weisselberg, 70, began working for the Trump Organization as an accountant in the 1970s, when President Donald Trump's father, Fred, ran the company. Weisselberg was also treasurer of the Donald J. Trump Foundation, the president's charitable organization, which has been sued by the New York attorney general for alleged violations of state law.

Cohen mentioned Weisselberg's name several times on a recorded phone conversation with Trump about a payment to kill a story about Trump's alleged relationship with Playboy model Karen McDougal. The tape was seized during the FBI's April raid on Cohen's residence and office, and was released to the media by Cohen's attorney, Lanny Davis.

On the tape, recorded two months before the 2016 presidential election, Cohen mentions that he has spoken to Weisselberg about setting up a corporation to process the payment.

"I need to open up a company for the transfer of all that info regarding our friend David," says Cohen, "so that — I'm going to do that right away. I have spoken to Allen Weisselberg about how to set the whole thing up with funding."

"David" is apparently David Pecker, a Trump friend who is the chairman and CEO of American Media and publisher of the National Enquirer, which had agreed to purchase McDougal's story.