"Long live Islam. Destroy Denmark. Destroy Israel. Destroy George Bush. Destroy America," shouted the protesters who on Friday marched in a steady rain to the Denmark Embassy from a nearby mosque in the capital Kuala Lumpur.
It was the second week that demonstrators have targeted the embassy after Friday prayers. But last week's protest attracted only about 300 people, in a country viewed as a model of a tolerant, modern Islamic state.
The protest came a day after the government ordered a nationwide ban on possessing or distributing the cartoons of the Prophet Muhammad first published in a Danish newspaper that have outraged the Islamic world, saying they could trigger public tensions.
"You are playing with fire Denmark. We are ready to fight," said Hanifah Maidin of the youth wing of the pan-Malaysian Islamic Party, which organised the protest.
Speakers condemned Danish and European newspapers for publishing the caricatures, demanding an apology from the Danish government. Riot police stood guard in front of the high-rise building where the embassy is located, as a police helicopter hovered above.
An English-language banner held aloft read: "Distasteful depiction of the prophet is a declaration of war against Islam", while some protesters waved pictures of Iranian Islamic revolutionary leader Ayatollah Ali Khomeini.
In a statement late on Thursday, the Internal Security Ministry, headed by Abdullah Ahmad Badawi, the Prime Minister, said it was an offence for anyone to publish, produce, import, circulate or possess the caricatures.
The measure was ordered to curb the circulation of material that could cause uneasiness among Malaysians and disrupt public order, the ministry said.
"You are playing with fire Denmark. We are ready to fight"
The statement did not specify what penalties could be imposed on offenders, and ministry officials couldn't immediately be reached for further details.
The move came as the ministry ordered a small Malaysian newspaper, the Sarawak Tribune, to cease publication indefinitely after it reproduced one of the caricatures last weekend.
The Tribune's publishers apologised for what they called an editorial oversight, but the ministry said the newspaper had to be penalised because its action was "irresponsible and insensitive" to Muslims.
Malaysia's newspapers operate under government licenses that must be renewed yearly and bar them from publishing potentially provocative material on religion, race and other topics.