When traveling to UAE, you need to avoid carrying the banned items in UAE, which may lead to imprisonment or deportation. Here is a related article from Dubai Government Website.
The UAE government prohibits drugs, narcotics and chemicals and before you enter the UAE, you are advised to take all precaution to ensure that you do not carry such substances; either in person, your luggage or in medicines you may be carrying. Strict penalties include imprisonment followed by deportation. Other banned items include pornographic material, non Islamic religious pamphlets for missionary activities, fireworks, ivory, weapons & ammunition, chemical and organic fertilizers, laser pens, radar jammers/other unauthorized communication devices, endangered animal species, and any objects, sculptures, paintings, books or magazines which do not adhere to the religious and moral values of the UAE. Adults coming in through Dubai Airport are permitted to purchase cigarettes and alcohol (only non-Muslims), as per Dubai Customs laws. Do ensure that your medicine does not contain a banned or restricted substance. See list of UAE restricted and controlled medicines or drugs. (49 page PDF download). Another specialized list mainly for pharmacists, but also useful is the Complete Guide to Management of Controlled Drugs in the Private Sector, issued by the General Authority for Health Services, Abu Dhabi. (29 page PDF download). If your medicine contains any banned or restricted substance, it is advisable not to carry them on your flight/travel into the UAE. However, if for medical or emergency reasons, you need to carry any medicines, please ensure that you have a medical prescription from a UAE-licensed doctor, or if treatment was undertaken abroad, you must carry both a doctor’s prescription as well as a detailed medical report, both of which should be suitable attested. You are not permitted to bring more than three month's supply of medicine, as per guidelines of Ministry of Health. Besides the narcotics listed, all other recreational drugs including cocaine, heroin, cannabis and opiates and its derivatives are banned. Be careful of carrying in poppy seeds which are banned, so avoid accidentally carrying bakery products that might contain such seeds. Also banned is qat leaf, betel leaf or nuts, niswar, gutkha, which while admissible in some countries is not permitted in the UAE. Do also keep in mind that on your flight out from any UAE airport, you need to comply with new regulations regarding liquids in your hand luggage, which should be contained within a transparent re-sealable plastic bag of not more than 1 litre capacity. Medicines and baby foods can be carried in your checked in luggage, but if you need medicines during your flight, you can place in your hand luggage, provided you have documentary evidence.
You could read more about it in the Dubai Government Website.