You want some painkillers, but you don’t want to go through the hassle of going to the doctor to get a prescription. It’s just a short-term issue and you really only plan to use them for a day or two. It doesn’t seem worth it.
One of your friends tells you that they have some leftover medication from when they had surgery. They recovered well and didn’t need it all, but they also did not throw it away. They offer to give it to you. Is that all right?
This doesn’t feel anything like the cliche drug deal happening in the shadows in an alley, but it is still illegal. Any sharing of prescription medication, or use of that medication, is prohibited. The only person who is allowed to use the medicine is the one to whom it was prescribed by a doctor.
It’s easy to imagine that this law applies only to selling drugs, in an effort to keep people from making money selling old medications, but that’s not how it works. Simply sharing the medication, or giving it away for free, is also illegal. It doesn’t matter if the person is a friend or even a family member. It doesn’t matter if the person giving away the medication was just trying to help. The best of intentions, or ignorance of the law, does not make it any less illegal.
All that said, this is a mistake people make all of the time. If you find yourself facing drug charges just because you did not know you were breaking the law, you absolutely need to understand your legal defense options.