A 28-year-old Tampa woman was charged with distributing heroin and fentanyl leading to a death, according to investigators -- who said they nabbed her with the help of an undercover officer who posed as a dead man.

United States Attorney Maria Chapa Lopez said in a statement that Joamary Rosario allegedly “sold 10 plastic bags — each of which contained a substance composed of a mixture of heroin, fentanyl, and acetyl fentanyl” — to a man who died in early November.

The next night an undercover law enforcement officer posed as the dead man to nab Rosario, who “was arrested and found to be in possession of three more bags of the same substance,” the release said.

CLICK HERE TO GET THE FOX NEWS APP

If convicted, Rosario faces a minimum mandatory penalty of 20 years, and up to life, in federal prison.

The case, investigators said, was part of the Middle District of Florida’s anti-opioid strategy to combat opioid trafficking and abuse.