Senator Bernie Sanders says he doesn't want the $2,700 campaign donation from the pharma drug executive he once called the "poster child of greed," but he won't give it back either.

Instead, Sanders said he is sending a check for the same amount to the Whitman-Walker Heath, a clinic in Washington, D.C.

The unwanted donation came from Martin Shkreli, who was publicly pilloried when he raised the price of a cancer and AIDS drug by more than 5,000%.

Shkreli, the CEO of Turing Pharmaceuticals, became known as the "most-hated man in America" after he bought Daraprim, a 62-year old drug that no longer had patent protection and jacked up the price to $750 a pill from $13.50 a pill. The drug is used to fight life threatening parasitic infections and can be important to AIDS and cancer patients, including infants.

The price hike brought attacks on Shkreli from both Hillary Clinton and Sanders, among others. Sanders has proposed regulating prices for drugs, saying the lack of such price controls in the United States has "been an unmitigated disaster."

Related: Free college and healthcare for all - How would Bernie Sanders pay for it?

During the first Democratic presidential debate Tuesday night, Shkreli tweeted "Damn @BernieSanders is my boy with that Kosovo reference. Gets my full endorsement. I did donate to him."

Damn @BernieSanders is my boy with that Kosovo reference. Gets my full endorsement. I did donate to him... — Martin Shkreli (@MartinShkreli) October 14, 2015

The Sanders campaign acknowledged receiving a $2,700 check from Shkreli, but said it doesn't want to keep the money and is sending a check for the identical amount to the D.C. clinic.

Shkreli and spokesmen for Turing did not respond to requests for comments about the donation. But Shkreli, 32, responded on Twitter that "I appreciate @BernieSanders using my contribution as a continuation of my philanthropy." He also tweeted, "Instead of having an intelligent discussion on healthcare @BernieSanders would rather hold his hands over his ears and be a demagogue.."

Related: No ready-made Rx for rising drug costs

Shkreli told the wire service Stat that he made the donation partly because he supports some of Sanders' proposals — just not the ones about drug prices. But mainly, he said, he donated to get the senator's attention in the hopes that he could get a private meeting to explain why drug companies set prices the way they do.

Shkreli also used Twitter to press his case on the justification for raising the price of Daraprim, saying the money is needed to develop a new version of the drug. In one tweet he asked Clinton and Sanders to answer the following questions:

Related: Drug company that hiked price 5,000% now under antitrust probe

"Would you prefer (1) a lower price of our medicine, which is overwhelming paid for by 'corporate America' and their insurers (who are reporting record profts) or (2) that we use our resources to research a new drug for resistant strains of this neglected disease. Does it make sense that we're using a 70-year old drug to treat an ever-evolving parasite."