I appreciate your frustration, but comparing the two isn't really valid.
Harm reduction programs (like those vending machines) are there to prevent the spread of diseases, not for getting around rules for personal convenience. Different problems, different approaches.
That being said, you're right about the bureaucratic states that require a prescription. I'm now curious about *why*...