Martin Shkreli, the controversial ex-drug executive now facing federal criminal charges, nearly doubled the money he invested in KaloBios, the drug company he briefly ran last fall.

Shkreli started buying shares of KaloBios (KBIO) last November when it was a penny stock, about a month before he was arrested. At the time, the company was in bad shape, winding down operations and liquidating its assets.

Shkreli paid just over $3.2 million for a controlling stake in the company, according to an SEC filing last fall.

Related: Martin Shkreli's E*Trade account takes a huge hit

The company announced on Monday that Shkreli sold his entire stake in the company a private transaction. He received $3.10 a share, according to a filing, which comes to a total of $5.9 million. That means he made a $2.7 million profit on his initial investment. Shkreli could not be reached for comment.

News of Shkreli's investment back in November briefly gave new life to the stock and the company, lifting its shares 400%. He was named CEO and promised to hire back employees who had been laid off before he bought his controlling stake.

But within weeks federal authorities arrested Shkreli, charging him with running a Ponzi scheme and looting funds from another company he had run. He is still awaiting trial on those charges.

Following his arrest, Shkreli was out as CEO of KaloBios, and also stepped down as CEO of Turing Pharmaceutical, a position he held simultaneously. It was at Turing that he became famous, and reviled, for raising the price of a drug needed by AIDS patients by 5,000%.

Soon after Shkreli's arrest KaloBios filed for bankruptcy. It emerged from bankruptcy earlier in June. Shkreli retained a major stake in the company through the bankruptcy process.