You're trying to apply western logic to Middle Eastern thinking. In the West, something is either illegal, or it isn't. Here, something is illegal if somebody decides that is, and it isn't if they decide that it isn't. Also, you're trying to find written references to laws...this isn't the right part of the world to expect things to be clearly spelled out in black and white. On a monthly basis those of us who live here come up against a new law, or interpretation of the law, that is not written down anywhere and we've long since given up trying to find out where it's written down...
But anyway, back on topic. Prostitution is illegal; drinking without a licence is illegal. But generally, unless you screw up in some other way, you're unlikely to be prosecuted for doing these things, particularly if you're a tourist.