When you learn how to speak Indonesian/Malaysian, you have to learn two different ways of greeting people. The first is the non-Islamic way of greeting someone whom you run into on the street. While you could be technically correct and say selamat pagi/siang/sore/malam ("good morning/afternoon/evening/night"), the idiomatically correct way to greet someone is to say mau ke mana? ("where are you going?"). In Malaysia, the words are different, but the meanings are the same for this non-Islamic greeting. Another way people sometimes greet someone is to say sudah makan? ("have you eaten yet?"), but although we learned this in our classes, we have never heard this as an actual greeting.
The Islamic way of greeting someone is to say assalamu’alaikum, which is Arabic for "peace be with you". The response is walaikum salam, which seems to mean basically the same thing.
You wouldn’t think that a greeting would be such a big deal, but it can be. When we learned Indonesian, we learned that when you arrive at someone’s house, you always announce your presence with a loud assalamu’alaikum, no matter if the house belongs to a Muslim or not. When you meet someone on the street, you probably will use a casual non-Islamic greeting. Two devout Muslims might use assalamu’alaikum, especially at a mosque or during prayers, but that’s it. As far as we can tell, in Indonesia these social conventions are still at work. Also, as far as we can tell, this is how things used to be in Malaysia before about three decades ago.
However, the social conventions around greetings in Malaysia have been in flux since the 1970s, with the rise of the dakwah or "religious awareness" movement in Malaysia. The best example of this is a story related in an article by Michael G. Peletz ("Sacred Texts and Religious Words," Comparative Studies in Society and History 35(1), 1993), an anthropologist who lived in a Malay village from 1980-81 and again from 1987-88. When he first arrived in 1980, his fellow villagers told him that it was considered very proper and polite for him to use assalamu’alaikum when greeting Malay villagers. Yet by late 1987, he was being reprimanded by local government leaders for being a non-Muslim who used this Islamic greeting. Of course, his efforts to figure out the rules, so as not to offend anyone, were fruitless; he describes, for example, the problem of what to do when a Malay villager greets him with assalamu’alaikum–is he supposed to respond with walaikum salam or not?
Although this is the case, we have yet to hear anyone in Malaysia use the traditional Islamic greeting. This is probably because we live in KL and have spent no time in villages. Everyone we meet here just says selamat pagi/tengah hari/petang/malam (the Malay equivalant of the Indonesian above) when addressing us. In our attempts at evesdropping on Malay greetings, we normally just hear "hello" or something suitably Anglicized like that. It’s good that we haven’t had to deal too much with the assalamu’alaikum problem, because it seems like it could be a source of hurt feelings. We have had a sort-of similar experience with the phrase insy’allah, which means "God willing" or more generally, "hopefully". There is a non-Arabic expression with a similar meaning that it completely non religious (mudah-mudahan), but people rarely use it. In Indonesia, our Muslim acquaintances always used insy’allah with us and made it clear that we should use it too. Here, sometimes people seem to accept it, and sometimes people seem not to like it. We’ve reverted to mudah-mudahan.
There’s a series of related stories regarding Islamic words in Malay. Since the mid-1980s, the Malaysian government has progressively strengthened regulations banning the use of "Islamic words" in Bahasa Malaysia when the context is non-Islamic. This is most contentious in Bahasa Malaysia translations of the Bible and the Adi Granth, the Sikh Holy Book. The government in several cases, most recently in Sarawak, has banned the publication of these books because they use "improper" Arabic/Islam derived words. So even though the word for "Bible" has always been al-Kitab ("the Book") in Malay, the government has declared that Malay translations must call themselves Baible. We don’t know much about the problems that Sikhs face, but other words considered improper for Christians include nabi (prophet), firman (believe), Allah (God), and about twenty-five others which have to be replaced with a non-Arabic/Muslim equivalent. Our position on this is naturally that such laws are unbelievably stupid and not a little petty. Apparently the government is unaware that in the Arab speaking word, Arab Christians almost always use the word Allah to refer to God. Why? Because the Arabic language precedes Islam.