According to sources familiar with Lindsay's most recent probation report, LiLo has a prescription for Dilaudid -- an extremely powerful painkiller ... often compared to morphine ... and even heroin.
As long as she has the prescription, Lohan is in the clear to pop the painkiller -- presuming she follows the dosage guidelines. We're told a doctor wrote the prescription after Lindsay's recent dental surgery. We do not know the quantity the doctor prescribed.
But as we first reported, that's not all she's allowed to have in her medicine cabinet -- Lindsay also has prescriptions for two other drugs -- Ambien and Adderall.
Linds -- who just got sentenced to 90 days behind bars -- is still subject to drug testing before she surrenders on July 20.